Eclipse: Failed to create Java Virtual Machine

Just downloaded the latest version of Eclipse version 3.6.1 from Eclipse.org. After zip file extraction, I was ready to check out the latest Eclipse; unexpectedly, I ran into an error prompt read as “Failed to create Java Virtual Machine”. Bam, why?!?!

After some tinkering, I was lead to the eclipse.ini file and found out some add-on configuration added in this latest version. "–launcher.XXMaxPermSize”. By removing the dafault value 256m, I’m now able to run it. :)

My eclipse.ini file now read as below:

-startup
plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar
–launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.1.R36x_v20100810
-showsplash
org.eclipse.platform
–launcher.XXMaxPermSize
–launcher.defaultAction
openFile
-vmargs
-Xms40m
-Xmx384m

For more information about the latest eclipse.ini, check out the link below:

http://wiki.eclipse.org/Eclipse.ini

http://wiki.eclipse.org/FAQ_How_do_I_increase_the_permgen_size_available_to_Eclipse%3F

 

 

I don’t get paid for writing blog posts. Your “Votes” and “Like” is my only motivation, so please “Like” it if you found this information useful. Cheers!!!

Check out what other says about this post by clicking at the title of this post.

112 comments

  1. This initially fixed my issue, but then Eclipse crashed soon after and now I get the issue again. And this time I can’t get past it!

    I have no idea how this happened all of a sudden.

  2. I noticed in combination with VE 1.5 and some open VE edit windows that this was blocking the startup of exclipse. I Applied the suggestion by removing the value 256m. But that triggers a running eclipse at 100% CPU. jvisualvm.exe showed 100% time in GC. So I changed to a value of 128m and now all started fine. jvisualvm showed that for Eclipse 3.6.1 EE and some extra plugins, I need at least 80m in Perm. The default might be too low (removing the 256m values).
    Also be careful with the -XmsNNNm option. It will be applied to each javaw.exe for each opened VE editor. So you might run out your OS memory quickly.

  3. Thanks,
    but in my eclipse.ini file I also remove the last parameter :
    -Xmx384m,because without that it still didn’t work!
    But however thank you very much

  4. yeah just remove the default value 256 from –launcher.XXMaxPermSize 256m

    and the newly added heap size wud automatically become the default one…
    it wud wrk fine then……..Gud LUCK

  5. You can also supply the VM Arguments by navigating to Window->Preferences->Java->Installed JREs and then select the (current) JRE click Edit button. Provide the VM arguments such as “-Xms256m -Xmx512m -XX:PermSize=512m” (these values changed based on your requirement) in the “Default VM Arguments” text field.

    Thanks
    Dandapani Parasa

  6. Thank you! I just allowed one of Aptana’s updates to run. A restart of Aptana gave me that message. Making the change you suggest fixed it. Thank you, thank you!

  7. Add the -vm argument in the eclipse.ini file. Eclipse will then locate the JVM and it will work fine.

    -startup
    plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar
    –launcher.library
    plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.1.R36x_v20100810
    -product
    org.eclipse.epp.package.jee.product
    –launcher.defaultAction
    openFile
    –launcher.XXMaxPermSize
    256M
    -showsplash
    org.eclipse.platform
    –launcher.XXMaxPermSize
    256m
    –launcher.defaultAction
    openFile
    -vm
    C:Program FilesJava\binjavaw.exe
    -vmargs
    -Dosgi.requiredJavaVersion=1.5
    -Xms40m
    -Xmx512m

  8. It worked for me too!!
    The problem started after I installed another eclipse and for that changed the Java_Home path to 1.6 where as the original eclipse used to point to 1.5
    After the machine restarted, the original eclipse used to give the error message(JVM something). I removed the xxpermsize and it started working again.

  9. Thanks a million ! Helped start the myEclipse 10.

    Have 1 question

    I increased Xms and Xmx values. Do they really apply to all java processes spawned ?

  10. This is what worked for me:

    Remove these two lines from the config file:

    -showsplash
    org.eclipse.platform

    The splashscreen needs a Windoze dll (COMCTL32.DLL) to display the splashscreen before the vm starts. If this .dll happens to open in the middle of your memory space, the java vm can’t allocate a large enough contiguous block of RAM for the object heap. By disabling this flag, the vm will start and then display the splashscreen. Problem solved.

    http://www.eclipsezone.com/eclipse/forums/t104307.html

  11. It’s good to know that it worked for u :)
    My eclipse.ini contents are these:
    #This configuration file was written by: org.eclipse.equinox.internal.frameworkadmin.equinox.EquinoxFwConfigFileParser
    #Mon Sep 17 23:14:57 CEST 2012
    org.eclipse.update.reconcile=false
    eclipse.p2.profile=SDKProfile
    osgi.framework=file:plugins/org.eclipse.osgi_3.7.2.v20120110-1415.jar
    equinox.use.ds=true
    eclipse.buildId=2.1-M2-20120917-Typesafe
    osgi.bundles=reference:file:org.eclipse.equinox.simpleconfigurator_1.0.200.v20110815-1438.jar@1:start
    org.eclipse.equinox.simpleconfigurator.configUrl=file:org.eclipse.equinox.simpleconfigurator/bundles.info
    eclipse.product=org.scala-ide.sdk.product
    osgi.splashPath=platform:/base/plugins/org.eclipse.platform
    osgi.framework.extensions=reference:file:org.eclipse.equinox.weaving.hook_1.0.100.v20110502.jar
    osgi.bundles.defaultStartLevel=4
    eclipse.application=org.eclipse.ui.ide.workbench
    eclipse.p2.data.area=@config.dir/../p2

    I’m not able to solve this problem :( Do u know how to proceed? Thanks in advance.

  12. Hi there,

    I am Having lots of configuration with eclipse Helios and lots of Plug ins integrated.

    After updating ADT and some other plug ins , it is crashing and denying to work.

    when running eclipsec.exe from cmd it gives me following error

    “Javac {0} or above, which is required to build BlackBerry WebWorks application, is not found in your system.
    Job found still running after platform shutdown. Jobs should be canceled by the plugin that scheduled them during shutdown: org.eclipse.ui.internal.i
    de.IDEWorkbenchActivityHelper$4
    Job found still running after platform shutdown. Jobs should be canceled by the plugin that scheduled them during shutdown: net.rim.browser.tools.A.A
    .H”

    Please see if you can help .

    PS : I have tried your solution also but didnt work.

    Thanks
    Vaibhav

  13. Companies are competing among themselves to ascertain their charisma on
    the World Wide Web. The websites hosted may be owned by individuals or by large companies
    for promoting their businesses. com site
    to help you reach the most objective and informed decisions.

  14. A web hosting firm that provides a good level of support will have a recent backup of
    your web site restored very quickly, whereas a cheap web host with
    minimal support may rely upon you having made your own backups and the technical expertise to restore your website to its former glory.
    These services include business, personal
    and professional web hosts of their kinds. Many people are creating
    their personal blog and sharing what is inside of their mind.

  15. I feel that is one of the most vital information for me.
    And i am happy studying your article. But wanna
    observation on some normal things, The website taste is ideal, the articles is actually great :
    D. Excellent job, cheers