# First verify the version of Java being used is not sunjsk.Java-version# Get The latest Sun Java SDK from Oracle http://www.oracle.com/technetwork/java/javase/downloads/ Jdk-7u1-download-513651.htmlwget http://download.oracle.com/otn-pub/java/jdk/7u1-b08/jdk-7u1-linux-i586.rpm# Rename The file downloaded, just to being niceMV jdk-7u1-linux-i586.rpm\?E\=1320265424\&H\=916f87354faed15fe652d9f76d64c844 jdk-7u1-linux-i586.rpm# Install Javasudo rpm-i jdk-7u1-linux-i586.rpm# Check If the default Java version is set to Sun JDKJava-version# If Not then lets create one more alternative for Java for Sun JDKSudo/usr/sbin/alternatives--install/usr/bin/java Java/usr/java/jdk1.7.0_01/bin/java 20000# Set The SUN JDK as the default JavaSudo/usr/sbin/alternatives--config Java# Verify If change in SDK is done.Java-version
Procedure for installing and setting Sun JDK Java on Default Amazon Linux AMI