-
-
Save shyam/1940844 to your computer and use it in GitHub Desktop.
Procedure for installing and setting Sun JDK Java 6 on Amazon Linux AMI 64bit
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get latest Sun Java SDK in v6 from Oracle | |
wget http://download.oracle.com/otn-pub/java/jdk/6u31-b04/jdk-6u31-linux-x64-rpm.bin | |
# make it exec | |
chmod +x jdk-6u31-linux-x64-rpm.bin | |
# Install Java | |
sudo ./jdk-6u31-linux-x64-rpm.bin | |
# Check if the default java version is set to sun jdk | |
# Normally it says OpenJDK | |
java -version | |
# Lets create one more alternative for Java for Sun JDK | |
sudo /usr/sbin/alternatives --install /usr/bin/java java /usr/java/jdk1.6.0_31/bin/java 20000 | |
# Set the SUN JDK as the default java | |
sudo /usr/sbin/alternatives --config java | |
# Verify if change in SDK was done. | |
java -version |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment