Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

STS is failing to start on my machine

I was trying to setup Spring mvc projects on eclipse. Basic projects were working fine. But using restful services, jersey etc started giving so many errors related to dependencies. So I am planning to move on to STS.

I am using STS 2.9.2. It was giving me "failed to create java virtual machine". So I added

-vm C:\Program Files\Java\jdk1.7.0\bin\javaw.exe

to STS.ini. But now it is giving me following fatal error

enter image description here

Below is STS.ini

-vm
C:\Program Files\Java\jdk1.7.0\bin\javaw.exe
-startup
plugins/org.eclipse.equinox.launcher_1.2.0.v20110502.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.100.v20110502
-product
com.springsource.sts.ide
--launcher.defaultAction
openFile
--launcher.XXMaxPermSize
884M
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xmn128m
-Xms256m
-Xmx768m
-Xss1m
-XX:PermSize=384m
-XX:MaxPermSize=768m
  • Eclipse is working perfectly on my machine.
  • I don't want to use Maven or other build tools to solve dependencies related problem due to limited internet speed.
like image 533
Amit Kumar Gupta Avatar asked Dec 11 '12 03:12

Amit Kumar Gupta


3 Answers

Initially I was using STS zip version. Now I installed STS from executable. And it is working fine for me. I required to setup HOME variable, that's all.

Attaching the STS.ini from installed STS (for reference).

-vm
C:\Program Files\Java\jdk1.7.0\bin\javaw.exe
-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.200.v20120522-1813
-product
org.springsource.sts.ide
--launcher.defaultAction
openFile
--launcher.XXMaxPermSize
256M
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xms40m
-Xmx768m
-XX:MaxPermSize=256m
like image 67
Amit Kumar Gupta Avatar answered Nov 20 '22 13:11

Amit Kumar Gupta


Delete STS.ini file. then it runs correctly and creates a new STS.ini File Automatically

like image 4
Khalid Bin Huda Avatar answered Nov 20 '22 13:11

Khalid Bin Huda


I had the same problem yesterday morning. After googling, I saw that the following lines in the STS.ini file were missing (orange marked): STS.ini

After adding:

-vm

[full path to the javaw.exe]

everything worked again properly.

HTH

like image 3
user2902426 Avatar answered Nov 20 '22 13:11

user2902426