If you're new here, you may want to subscribe to my RSS feed and if you have questions related to your ubuntu system post question to our forums. Thanks for visiting!
The language itself derives much of its syntax from C and C++ but has a simpler object model and fewer low-level facilities. JavaScript, a scripting language, shares a similar name and has similar syntax, but is not directly related to Java.
Currently Ubuntu has the following Java packages
sun-java6-bin - Contains the binaries
sun-java6-demo - Contains demos and examples
sun-java6-doc - Contains the documentation
sun-java6-fonts - Contains the Lucida TrueType fonts from the JRE
sun-java6-jdk - Contains the metapackage for the JDK
sun-java6-jre - Contains the metapackage for the JRE
sun-java6-plugin - Contains the plug-in for Mozilla-based browsers
sun-java6-source - Contains source files for the JDK
Installing the Java Runtime Environment
First you need to check multiverse repository enabled or not after that open a terminal window. Since you are going to be installing the JRE and the web browser plug-in, you’ll be using the following command from a terminal
sudo apt-get install sun-java6-jre sun-java6-plugin sun-java6-fonts
Once it downloads the packages and begins the installation, you’ll get a screen that contains the Sun Operating System Distributor License for Java and hit Enter to continue. You’ll see a dialog that asks you if you agree with the DLJ license terms. Select Yes, and hit Enter; the JRE will finish installing.
Testing Java Runtime Environment
You’ll want to confirm that your system is configured properly for Sun’s JRE. This is a two-step process.
First, check that the JRE is properly installed by running the following command from a terminal.
java -version
You should get similar output
java version “1.6.0″
Java(TM) SE Runtime Environment (build 1.6.0-b105)
Java HotSpot(TM) Client VM (build 1.6.0-b105, mixed mode, sharing)
Testing Java Plugin for Firefox
open Firefox and typing about:plugins in the address bar and check for java plugin







Hi ya’ll this site has been really useful. Feel I’m getting more understanding here then other Ubuntu forums dealing with Ubuntu 10.04 and Pogo.
I ran the commands lines like posters have said, made the necessary corrections.
And this is my version of java, when run the java -version command.
java version “1.6.0_18″
OpenJDK Runtime Environment (IcedTea6 1.8) (6b18-1.8-0ubuntu1)
OpenJDK Client VM (build 14.0-b16, mixed mode, sharing)
AND
my firefox plugin for java
appears to still be using IceTea
Still new to Ubuntu, it may be different but I am liking it.
Matt’s answer worked for me as well, as I was getting error messages trying to use the console. Thanks!
Hi, I am VERY new to Ubuntu (first run). I have Ubuntu 10.04 and I tried the steps above, but when I typed these into the Terminal..It said:
Package sun-java6-jre 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.
I have no idea what to do. Any help please?
sun-java6-plugin has been replaced by icedtea6-plugin.
So install icedtea6-plugin ‘sudo apt-get install icedtea6-plugin’
Installing java has a different name too:
openjdk-6-jre
OK, thanks alot.
I keep getting this problem…
Err http://us.archive.ubuntu.com/ubuntu/ lucid-updates/main tzdata 2010j-0ubuntu0.10.04
404 Not Found [IP: 91.189.88.31 80]
Err http://us.archive.ubuntu.com/ubuntu/ lucid-updates/main tzdata-java 2010j-0ubuntu0.10.04
404 Not Found [IP: 91.189.88.31 80]
Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/t/tzdata/tzdata_2010j-0ubuntu0.10.04_all.deb 404 Not Found [IP: 91.189.88.31 80]
Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/t/tzdata/tzdata-java_2010j-0ubuntu0.10.04_all.deb 404 Not Found [IP: 91.189.88.31 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
I cannot not find the tzdata-java_2010j-0ubuntu0.10.04_all.deb file anywhere… even in there tzdata archives…
Should I remove OpenJDK after installing JRE in ubuntu lucid?