Eclipse closes as soon as workbench loads

Shashank.Kr picture Shashank.Kr · Jul 15, 2012 · Viewed 7.2k times · Source

I am having this problem for some weeks now, eclipse starts with splash screen, loads plugins, workbench etc, UI opens and closes immediately. I have tried everything possible, there are no log files generated in .metadata. Problem started with Helios then I installed Juno but still its same. I have tried installing JDK 1.6 , 1.7 again but didnt work as well.

What all i have tried :

1) All the possible changes in eclipse.ini, perm size, -vm argument 2) console with -clean and -clonsoleLog -debug option, no errors , problem persists 3) system restore to a previous date when Helios was working correctly

Please help me. Shashank

Answer

oiyio picture oiyio · Feb 25, 2016

After java update, eclipse will not start because default jdk location has changed. Adding the following lines to eclipse.ini file solved my problem immediately:

-vm
C:\Program Files (x86)\Java\jdk1.7.0_75\bin\javaw.exe

I added these lines just before vmargs. It looks like as the following :

...
--launcher.defaultAction
openFile
-vm
C:\Program Files (x86)\Java\jdk1.7.0_75\bin\javaw.exe
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Dhelp.lucene.tokenizer=standard
-Xms40m
-Xmx512m

For more information on eclipse.ini, visit this the site http://wiki.eclipse.org/Eclipse.ini#-vm_value:_Windows_Example