Installing Java 6 in Ubuntu 9.04

Right now I am using ubuntu 9.04 linux, to forget that expensive, usafe and slow experience. For insatalling java in Ubuntu 9.04, I do have to make come changes and followed some instruction. So here is those steps that i had followed to install java in Ubuntu 9.04.

Step 1:

Open terminal and run

$ sudo gedit /etc/apt/sources.list

Step 2:

sources.list file will get open.

Check whether there is given repository link or not, if not then add these lines at the end of the file.

deb http://us.archive.ubuntu.com/ubuntu dapper main restricted

deb http://us.archive.ubuntu.com/ubuntu dapper universe multiverse

Step 3:

After closing sources.list with save, we have to update it’s repository.For that run:

$ sudo apt-get update

Step 4:

Now we are about to install Java 6, But before install we have to map the dependencies with this instruction

$ sudo apt-get -f install

Step 5:

Finally, we have to install Java with this instruction

$ sudo apt-get install sun-java6-jre sun-java6-jdk sun-java6-plugin

(If you are beginner in ubuntu, you might not get idea to click <Ok> which you will get on configure window. For that you have to use TAB button and then ENTER>

Step 6:

Verification of Java installation

$ java -version

This instruction display the installed version of the Java.