Pages

Google Ads

Friday, August 13, 2010

How to install Sun JDK 1.6 on Ubuntu 10.04 (linux)

Hi folks,

Yesterday I upgraded my Ubuntu 9.10 to the new Ubuntu 10.04 on my laptop DELL Vostro 1310.

The new version of Ubuntu is pretty and it looks like you are using a mobile phone.

So let me share with you guys how to install Sun JDK 1.6 on Ubuntu 10.04 because it is not just type sudo apt-get install sun-java6-jdk on command line.

Below you can see the message you will receive after you try to install JDK 1.6 on Ubuntu 10.04 using the common way.

"Package sun-java6-jdk is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package sun-java6-jdk has no installation candidate"


Just follow the commands below:

What I did to solve this problem was to add a new source

sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"

After that just do the normal way.

sudo apt-get update sudo apt-get install sun-java6-jdk

That's it. It worked for me.

No comments: