Add the repository and then update Ubuntu...Then you can use the same old command $ sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner" $ sudo apt-get update $ sudo apt-get install sun-java6-jdk or {Depending upon what you need) $ sudo apt-get install sun-java6-jre