Oracle Java Virtual Machine install?
Solution 1:
You can use
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-jdk7-installer
This will install Oracle JVM and will update it when needed.
But if you want to install JVM manually, you should use these commands:
tar -xzf jre-7u51-linux-i586.tar.gz
sudo mv jre1.7.0_51/ /usr/lib/jvm/jre1.7.0_51
Then run
sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jre1.7.0_51/jre/bin/java
and
$ sudo update-alternatives --config java
There are 3 choices for the alternative java (providing /usr/bin/java).
Selection Path Priority Status
--------------------------------------------------------------------------------
* 0 /usr/lib/jvm/java-6-openjdk/jre/bin/java 1061 auto mode
1 /usr/lib/jvm/ia32-java-6-sun/jre/bin/java 63 manual mode
2 /usr/lib/jvm/java-6-openjdk/jre/bin/java 1061 manual mode
3 /usr/lib/jvm/java-6-sun/jre/bin/java 63 manual mode
4 /usr/lib/jvm/jre1.7.0_51/jre/bin/java 4 manual mode
Press enter to keep the current choice[*], or type selection number:
Follow the instructions on screen. Your numbers would be quite different from mine.
Solution 2:
If you want to have Java 7, follow this:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer oracle-java7-set-default
Oracle java is better than the openjdk in terms of performance IMO