4

Before installing Eclipse, I had OpenJDK as the default JVM. Recently I changed it to Sun Java.

I did this because Eclipse Helios was running really slow. Unfortunately, it is still slow... Do you have any ideas how to force it to use Sun Java?

I could reinstall Eclipse, however I have already installed the Android SDK, so I would have to install that again. After all, I don't think that's the correct way of solving the problem. I'm using Ubuntu 10.10.

$ java -version  
java version "1.6.0_22" 
Java(TM) SE Runtime Environment (build1.6.0_22-b04) 
Java HotSpot(TM) 64-Bit Server VM (build 17.1-b03, mixed mode)

I would be grateful for any help.

Jason Plank
  • 2,336
  • 5
  • 31
  • 40
Dan
  • 179
  • 1
  • 4
  • 8
  • If you have similar problem - you are working on Eclipse with Android, and Eclipse is running so slow, firstly check which version are you using. There are some bugs in 3.6 Helios:/ The easiest way is to get e.g. 3.5 ver. – Dan Jan 18 '11 at 19:06

2 Answers2

7

Edit $ECLIPSE_HOME/eclipse.ini and add the following before the vmargs option.

-vm
/opt/path/to/sun-jdk-1.6.0.02/bin/java
dogbane
  • 266,786
  • 75
  • 396
  • 414
3

You can tell Eclipse which VM to use using -vm command line args.

See Eclipse wiki for example usage

skaffman
  • 398,947
  • 96
  • 818
  • 769
  • thanks that works, I was on Eclipse wiki before however I have not noticed that:/ – Dan Jan 16 '11 at 16:50