Tuesday, April 26, 2011

Eclipse - "Failed to start the Java Virtual Machine"

I recently had downloaded Eclipse onto my new work laptop and had issues with getting it started. The splash screen would come up and then a dialog reading "Failed to start the Java Virtual Machine" would pop up.

Again, google comes to the rescue and lets me know that the java version is not explicitly specified by default, and you could do so in the workbench.ini file by using -vm. My ini file looks a bit like this now;

--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vm
C:\Program Files\Java\jre6\bin\javaw.exe
-vmargs
-Dosgi.requiredJavaVersion=1.6
-Xms40m
-Xmx512m
I was able to get this and other information from http://wiki.eclipse.org/Eclipse.ini

No comments: