myNotes

notes on my work that worth sharing. A semi-coherent receptacle for Jeeshen Lee.

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.

Filed under: Software Development, ,

77 Responses

  1. fangzx says:

    Thanks!

  2. nemanja i nebojsa says:

    cheers mate :)

  3. Greg says:

    Fixed my problem, thanks!

  4. Jerry says:

    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.

  5. jeeshenlee says:

    Jerry, which version of Eclipse you downloaded? Did you tried to re-install your Java virtual machine?

  6. datha says:

    Thank you very much.

    It’s work!!

  7. Subbu says:

    I had the same problem after increasing my heap size in the ini file. After I removed the default value for the perm size it worked fine.

    Thanks you.

  8. Luis says:

    Thanks, your advice helped me.

    I am just wondering how the –launcher.XXMaxPermSize 256m got into the eclipse.ini file, because I never changed the file myself.

  9. jeeshenlee says:

    Hellu Luis,

    Glad that it helps. The -launcher string was added by default when we download the installer from Eclipse. :)

  10. eremmel says:

    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.

  11. jeeshenlee says:

    @Eremmel, that explain one of the question sent to me days (via email) earlier on this topic. THANKS for sharing!! Hope your input will help others as well. :)

  12. Helen says:

    I just wanted to thank you for creating this post – I did what you suggested and eclipse is now working fine. I’m very gratfeul!

    Helen

  13. Helen says:

    Thanks for creating this post. I did what you suggest and eclipse is now working fine. Thanks so much!

    Helen

  14. jeeshenlee says:

    @Helen, no problem. ;)

  15. pr@tt says:

    Thx, it’s really works!!!!!!

  16. nizam says:

    It really worked. Thanks a lot.

  17. carsten says:

    thanks!

  18. x_ninja_x says:

    Thanks!!!

  19. PRRomaP says:

    GOOD & CLEAN Solution!
    Thx!

  20. PRRomaP says:

    GOOD & CLEAN Solution!
    Thx!

  21. Cliff says:

    Thank you!

  22. [...] The busiest day of the year was November 19th with 215 views. The most popular post that day was Eclipse: Failed to create Java Virtual Machine. [...]

  23. José says:

    Thank you very much, it helps me so much!

  24. James says:

    Thank you for this aid. It has shortened my startup time with Eclipse immensely.

  25. Pradnya says:

    Thanku so much u saved me….:)

  26. sriram says:

    Thanks it worked. Cheers!!!

  27. D.D. says:

    Ditto, this worked for me also.

  28. kvr2277 says:

    Thanks..

  29. Madhavan says:

    Thanks…

  30. Sunil says:

    Thanks It worked

  31. Gaurav Kumar says:

    Thanks a lot.

    I am able to run Eclipse by removing 256M.

    Thanks again.

  32. nikhil says:

    Thanks a lot , i am able to run Eclipse now

  33. Amateur Barista says:

    It worked!

  34. senthil kumar says:

    Its working now thanks a lot :-)

  35. Pier-Luc Gagnon says:

    Thanks, it really saved my day!

  36. Arsen says:

    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

  37. Sonia Solis says:

    Thanks , it worked :)

  38. rejie says:

    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

  39. Jack says:

    Thanks. That resolved my same issue.

  40. jun says:

    I found that the Eclipse puts 256m on a separate line.
    I changed it to “–launcher.XXMaxPermSize 256m”

    It works too.

  41. jun says:

    Sorry, guys
    My bad. Please ignore my change. With the change, the Eclipse will report error at the exit time.

  42. jeeshenlee says:

    @Jun, thanks for sharing though ;)

  43. 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

  44. Andy Jarrell says:

    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!

  45. Sachin says:

    This actually works…Thanks a lot for great comment…This post has helped me a lot

  46. mbv says:

    I just had the same error, and the problem was that the line read 256M instead of 256m. That solved the problem for me.

  47. Donald says:

    Right on the spot, thanks

  48. makertips says:

    Thanks a lot, dude.
    This worked for me too …

  49. Narendran says:

    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 Files\Java\\bin\javaw.exe
    -vmargs
    -Dosgi.requiredJavaVersion=1.5
    -Xms40m
    -Xmx512m

  50. J-Hong says:

    In my case, @Narendran’s way works. Thanks.

  51. Mithil says:

    dude.. you made my day man… after a long time.. i got this eclipse issue fixed.. thanks a lot man…:)

  52. whiterain says:

    thanks
    problem solved.

  53. Thanks, Solved My Problem

  54. Muhammad Sajjad Awan says:

    thanks buddy ..problem solved

  55. bihag says:

    thanks man, problem solved

  56. Ziggy says:

    Thanks! I’m now verry happy! :D

  57. niks says:

    Works like a charm!!! Thanks…

  58. civika says:

    thanks buddy!!!!!! it worked:-)

  59. Kamlesh says:

    Thanks a lot for your information….such a nice examination

  60. raj says:

    it worked thanks a lot. by the way how come this value gets added to the ini file?

  61. Wow thanks a lot, quick fix indeed!

  62. siraykut says:

    Süper. Thanks for this article .

  63. Ananthan says:

    It works!!!!!!!!!!!!
    Nice Job Dude!

  64. Prady says:

    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.

  65. Ambar says:

    Thanks! It worked like a charm. :)

  66. Orange says:

    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 ?

  67. Orange says:

    Correction, removing that value did not start the myEclipse. I had to restore the original set of values

    -Xmx768m
    -XX:MaxPermSize=256m

  68. Bharath says:

    Thank Q So Much….:)

  69. Aravindan says:

    Thank you Boss, Really helped me a lot.
    After a lot of struggle, your tips really worked for me

  70. Eddie says:

    Thanks! Totally worked! But, why? My version was the windows 32 bit indigo jee

  71. Damodar Prasad says:

    thanks its save my lots of time.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Find me on:

facebook twitteryoutube

rss maillinkedin

slideshare picasastumbleupon

Follow my Tweets

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 10 other followers

Blog Stats

  • 118,197 hits

I spy :) Thanks for visiting.

Hello World!

flag counters

jeeshenlee@yahoo.com

Chat with me. I'm currently:
Yahoo Messenger Contact
Follow

Get every new post delivered to your Inbox.