Drop OpenJDK and upgrade Java to the Oracle packages

A few weeks back I started noticing some performance issues on my IDE and decided to investigate a bit more on it: turns out that they recommended to 1) upgrade to the latest JDK (7) and stop using OpenJDK, as it has some performance gotchas.

Turns out to be a no-brainer thanks to the apt repository manager provided by flexiondotorg:

1
2
3
4
cd ~/
wget https://github.com/flexiondotorg/oab-java6/raw/0.3.0/oab-java.sh -O oab-java.sh
chmod +x oab-java.sh
sudo ./oab-java.sh

After running it you just need to re-install all the packages:

1
sudo apt-get install oracle-java7-jdk oracle-java7-jre oracle-java7-plugin

and tell ubuntu that the JDK version and location has changed:

1
sudo update-alternatives --config java

A quick check with java -version and then enjoy it!


In the mood for some more reading?

...or check the archives.