Archive for January, 2001

Amazon EC2: Installing Java on Amazon EC2 ami

Monday, January 15th, 2001

WGET Oracle Java 8 SDK on Amazon EC2 or any Linux

Get the Java 8 rpm. See Java Download Page for later URL

Or using wget Java 8 u11 RPM like:

wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie"


# Install Java
sudo rpm -i jdk-8u11-linux-x64.rpm

# Check if the default java version is set to sun jdk
java -version

# If not then lets create one more alternative for Java for Sun JDK
sudo /usr/sbin/alternatives --install /usr/bin/java java /usr/java/jdk1.8.0_11/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

This came from source but a little modified with the wget cookie trick and new java version.