Install and Config Sun Java Runtime Environment: How-to.
[ ]
First, get the latest jre from SUN and get the rpm.
Go-to, and choose the rpm file.

Then install it using rpm
[lax@liulantao-com JAVA]$ sudo rpm -Uvh jre-6u12-linux-i586.rpm

Make the system recognize it.
[lax@liulantao-com ~]$ sudo /usr/sbin/alternatives --install /usr/bin/java java /usr/java/jre1.6.0_12/bin/java 100 --slave /usr/bin/rmiregistry rmiregistry /usr/java/jre1.6.0_12/bin/rmiregistry --slave /usr/share/man/man1/rmiregistry.1 rmiregistry.1 /usr/java/jre1.6.0_12/man/man1/rmiregistry.1 --slave /usr/share/man/man1/rmiregistry.1.gz rmiregistry.1.gz /usr/java/jre1.6.0_12/man/man1/rmiregistry.1.gz

Then we check the default version. See it, java is there waiting for U!
[lax@liulantao-com JAVA]$ java -version
java version "1.6.0_12"
Java(TM) SE Runtime Environment (build 1.6.0_12-b04)
Java HotSpot(TM) Client VM (build 11.2-b01, mixed mode, sharing)

Liu Lantao
College of Information Science and Technology, Beijing Normal University
EMAIL: liulantao ( at ) gmail ( dot ) com ;