This post is partly for Kris and partly for everyone else! Some people are probably wondering where Sun Java has gone to in Ubuntu 10.04 “Lucid Lynx”. It always pays to read the Release Notes, as they tell you that Sun Java has been moved to the Partner Repository. So, how do you install it? Firstly you have to activate the Partner Repository. Go to the System -> Administration -> Synaptic Package Manager. Enter your password. Go to Settings -> Repositories. Go to Other Software. Click on the link with “partner” at the end. See screen shot (right).
Click Close. Click Reload, so you get the new software showing up. On the left hand side, near the bottom of the window, click on Origin, and then select lucid/main (archive.canonical.com). In the main window you’ll see a number of items appear. Scroll down until you see sun-java6-jre. Right click on it and select “Mark for installation”. See screen shot (below). A message will pop up telling you that some additional stuff is required. Click on the green “Mark” tick. If you want Sun Java to work with Firefox, you will also need to right-click on “sun-java6-plugin” and “Mark for installation”. I also install the “sun-java6-fonts” package too.
Click on the big green “Apply” tick and wait for the install. You’ll need to tick the licence box and click Next. Now…you have Sun Java installed, but it is not the default Java Virtual Machine. If you ONLY want to use it (and this may be if OpenJDK/icedtea doesn’t work with a certain Java applet), then you’ll need to remove OpenJDK and “icedtea”. Search for “icedtea” in Synaptic and right-click on each “icedtea” and OpenJDK item you find and select “Mark for Complete Removal”, then click Apply. Now you should only have Sun Java. Enjoy!