Install Oracle Java on Deepin Linux 12.06 via PPA

This tutorial will show you how to install Oracle Java 7 on Deepin Linux 12.06 via PPA. The benefit of installing Java via PPA is easier and its good for future update of Java. If there is any java update, we can easily upgrade Java to the new version with ease. OK lets get through the installation steps.

How to install Oracle Java on Deepin Linux 12.06 via PPA

Open Terminal and paste these commands
sudo add-apt-repository ppa:webupd8team/java -y
sudo apt-get update
sudo apt-get install oracle-java7-installer
Once finished, check if java correctly installed by invoking this command
java -version
and it will returned something like this
dhani@dhani-deepin:~$ java -version
java version "1.7.0_05"
Java(TM) SE Runtime Environment (build 1.7.0_05-b05)
Java HotSpot(TM) Client VM (build 23.1-b03, mixed mode)
Now we need to enable the Firefox or Google Chrome Java plugin. 
cd /home/dhani/.mozilla/plugins
if plugin directory is not created yet, you can create a new one
mkdir /home/dhani/.mozilla/plugins
Change dhani with your own username and don't forget the dot (.) before mozilla text.
ln -s /usr/java/lib/i386/libnpjp2.so
Change "/usr/java" with your JRE installation directory.