Recently, for unknown reasons, starting up Eclipse gave me a nasty screen of errors, starting with:
JVM Terminated. Exit Code=-1
I've been using Eclipse and FDT for years, and this was the first time I've seen that so was stumped for a bit. Doing a search, gave numerous people running into similar problems, but frequently the error code was different, I'm not sure if "Exit Code =1" is a legitimate error or search engine indexing '-1' as '1'
What did work initially was removing the eclipse.ini, but then there wasn't enough memory being allocated for FDT (eclipse.ini has optional arguments '-Xmx' to tell the Java Runtime how much memory to save
Digging it turns
-vmargs was able to turn on/off the error. But then FDT wouldn't have enough memory to run
Having had the Java runtime recently upgrade itself to 1.6, thought that was most of it. In the end, along with some other nasty issues (Explorer.exe taking 50% of the CPU and taking down any process)...I just ended up reinstalling Windows....joy.
It's working now, it turns out that the first param needs to be in front of the others, and I've had stability issues when the value is high (e.g. MaxPermSize=512M). Even though I have 3GB Ram, something between the JVM and Windows doesn't like it.
-XX:MaxPermSize=256M
-vmargs
-Xms40m
-Xmx768m
[UPDATE 10-28-08]
There have been several suggestions in the comments, I got this exact issue again when installing FDT 3.1 stand alone. I tried renaming the eclipse.exe to eclipse1.exe, but this appears just to bypass the similarly named eclipse.ini, forcing it to restart to defaults. Which in my case with FDT 3.1 didn't work, as it needs lots of memory. Using the same approach of using an updated config file fixed it, which I've uploaded here:
fdt-3.ini (note rename it to eclipse.ini if you are using eclipse instead of the FDT version of eclipse.

{ 3 trackbacks }
{ 67 comments… read them below or add one }
← Previous Comments
Thanks, this sorted my issue.
I removed the existing JVM settings in the Eclipse.ini with your suggestion – now I’m running again
I’ve tried everything on the site with no results.
After I updated Eclipse to Galileo (was Ganymedes) it stopped working
I tried renaming the file, and the error message, while still exit code -1, just changed.
I installed a very old eclipse 3.2 that I found lying around, and that doesn’t work either.
Re-installing the java jre with the newest 64-bit didn’t for either eclipse.
I don’t know what else to try besides re-installing windows vista.
Maybe you have a rogue JVM? try uninstalling all the java JRE/JVMs, test Eclipse – it shouldn’t be able to start, then install the JRE that worked. try a fresh eclipse folder, that out of the box with no plugins shouldn’t give you any issues. Unfortunately I’m just shooting in the dark.
Being specific about the vm in eclipse.ini works.
-vm
c:\path..\javaw.exe
I believe QuickTime overrode the default jvm in XP.
Uninstalling & chocking if there are no rogues (there were none) and reinstalling didn’t work
These are the errors I get.
[IMG]http://i288.photobucket.com/albums/ll196/zomb1986/eclipseerror.png[/IMG]
Left the original eclipse.exe, right the one I renamed.
For your convenience, I highlighted in red the parameters that are missing on the right.
Waleed’s suggestion was an ez fix. Thanks!
Start Chrome and run the java test from java.com. This ‘jump started’ the JVM and then eclipse started working.
I was having the same issue with eclipse until I installed the Eclipse IDE for Java Developers
Facing the same error message with “eclipse-jee-galileo-SR1-win32″ in my Win XP. After long trying I simple removed in eclipse.ini this lines:
——————————————————
org.eclipse.platform
–launcher.XXMaxPermSize
256m
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xms40m
-Xmx512m
——————————————————–
now it starts and works!?
It looks people have found explanations and got their Eclipses going again. But I’d like to add one more thing to look for.
I had all the same problems with Eclipse. Mine turned out to be a virus: Packed.Win32.Krap.X, which had somehow invaded the heap address space of Eclipse. I ended up restoring Windows XP (although I should have tried a few more things suggested by Zone Alarm — I found them too late). Problem with Eclipse and my ancient Gnu Emacs went away.
By the way, changing the max heap size provided the clues that helped. I found it did not run with -Xmx256m but would run with -Xmx192m. Then I got a strange warning that my task manager had been disabled by an admin. That and a Google search being redirected to some place trying to sell me stuff.
I found the fix that worked for me!
I had to install 32-bit JRE beside my 64-bit JRE, and now it works. (I had to lie about my operating system on Sun’s website to obtain it O_o)
I found out about this through an unrelated update of Vuze, which complained it did not find a JRE, and after pointing it to it, it complained that it was damaged and not a valid 32-bit JRE.
Thanks buddy…
You saved lot of my time.. Thanks again..
I removed eclipse.ini and it worked
Cheers,
Amit
After following Diman suggestion, I was able to get eclipse working again.
btw, this might have happened when my PC was infected with InternetSecurity 2010 virus..
thanks.
This is what I have for the eclipse installed from this zip file eclipse-jee-galileo-SR1-win32.zip and it works. But changing the -Xmx to 2048m stops right there.
-startup
plugins/org.eclipse.equinox.launcher_1.0.201.R35x_v20090715.jar
–launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.0.200.v20090519
-product
org.eclipse.epp.package.jee.product
–launcher.XXMaxPermSize
256M
-showsplash
org.eclipse.platform
–launcher.XXMaxPermSize
256m
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xms128m
-Xmx1024m
I tired editing eclipse.ini nothing worked. Finally I deleted the file and similarly to Amit everything works fine again
.
T
I have a similar puzzling problem… i am invoking eclipse using these arguments
-vmargs -Xmx512m -XX:MaxPermSize=256m, it throws me the error JVM terminated exit code 1 …. error . If I reduce these numbers down to the default, it works fine
-vmargs -Xmx256m -XX:MaxPermSize=256m but later gives a out of memory error when executing the code. it even works up to Xmx487. not more than this!!!
Eclipse points to JDK1.5_0_22 and runs on windows server 2003 having more than 20 GB memory. I tried some of the options above like deleting the eclipse.ini . none of them works.
The same code runs fine on my laptop with 1 GB ram without any out of memory errors.
Any suggestions are welcome. thanks in advance.
Even i have same problem.I deleted eclipse.ini file and it started working
I was able to fond the solution for my issue, It was due to citrix presentation client restricting java from assigning more than a certain JVM heap space. The issue and the patch fix for this solution is present here – > http://support.citrix.com/article/CTX115868
← Previous Comments