Failed to create the Java Virtual Machine

由于项目里面用eclipse,今天从eclipse官网下载了一个Eclipse IDE For Java EE Developers,

版本:eclipse-jee-helios-win32

自己电脑上装的jdk版本是:1.6.0_20

解压后启动,发现弹出提示框“ Failed to create the Java Virtual Machine

 

 

 

 

 

 

 

 

解决方法:

找到eclipse目录下的eclipse.ini,可以看到如下内容:
-startup
plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar
–launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.0.v20100503
-product
org.eclipse.epp.package.jee.product
–launcher.defaultAction
openFile
–launcher.XXMaxPermSize
256M
-showsplash
org.eclipse.platform
–launcher.XXMaxPermSize
256m
–launcher.defaultAction
openFile
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xms40m
-Xmx512m
修改–launcher.XXMaxPermSize  128

如下:
-startup
plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar
–launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.0.v20100503
-product
org.eclipse.epp.package.jee.product
–launcher.defaultAction
openFile
–launcher.XXMaxPermSize
128M
-showsplash
org.eclipse.platform
–launcher.XXMaxPermSize
128m
–launcher.defaultAction
openFile
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xms40m
-Xmx512m

最多留言日志

声明: 本文采用 BY-NC-SA 协议进行授权 | javabk.com
转载请注明转自《Failed to create the Java Virtual Machine
标签:

这篇文章目前有12条评论

  1. sdupig: 2011-09-29 09:29

    改了之后确实可以了,这是为什么呢?

    沙发王 !
  2. moface: 2011-09-07 11:07

    对,是呢,改过之后倒是好了,但是什么原因呢?

    板凳党 !
  3. 汇泰龙: 2011-07-05 14:35

    其实这里有解释的:http://wiki.eclipse.org/Eclipse.ini

    地板砖 !
    • 汇泰龙: 2011-07-05 14:42

      我升级新版本后也出错了,修改一下Eclipse.ini,在其中加入
      -vm
      D:/Java/bin/javaw.exe
      保存后,打开Eclipse就正常了.其中D:/Java/bin/javaw.exe是我的Java虚拟机路径.
      一般出现这种情况跟安装了多个Java虚拟机有关吧,我自己就安装了1.5与1.6的,所以会出现这个情况.

      • Peggy: 2011-12-16 08:56

        This is both street smart and intlleigent.

      • easyfly: 2011-12-19 10:43

        我也是因为有多个虚拟机造成的。指定一个就解决了。

  4. yuyanchao2005: 2010-11-01 16:43

    非常感谢啊!

    4 #
  5. JeeShen Lee: 2010-09-24 23:41

    I come across the same problem and have fix it by modifying the ecclipse.ini file. Check the link below for more information.

    http://jeeshenlee.wordpress.com/2010/09/24/eclipse-failed-to-create-java-virtual-machine/

    Thanks.

    Regards,
    JeeShenLee

    5 #
  6. gavin: 2010-08-15 17:12

    good..thanks…

    6 #
  7. jerry: 2010-07-22 08:51

    我也遇到这个问题了,你知道标准配置为什么会出问题么?

    7 #
    • 蓝色爪哇鱼: 2010-08-04 10:52

      可能是电脑内存太低,如果是2G的内存的话肯定没问题。

      • sosoayaen: 2010-12-15 09:28

        我3G的内存照样报错,不是内存大小的问题。我把最下面的-xmx512修改成400,384之后就都可以开启,只要大于512就报错

Leave a Reply

(必填项)

(必填项)

(可选)

字体大小: 减小一号 减小一号
▲ Back to top 繁體