Just launched an instance of EC2 and I tried doing:

$JAVA_HOME/bin/java -version

it gives me back:

 $JAVA_HOME/bin/java -version
java version "1.6.0_20"
OpenJDK Runtime Environment (IcedTea6 1.9.1) (amazon-
OpenJDK Client VM (build 19.0-b06, mixed mode)

so I can see that it is installed there. I opened up my bash profile however I don't see what my JAVA_HOME path is? How do I get this? THanks




env | grep JAVA


Your java path is displayed from /etc/profile.d/aws-apitools-common.sh

If you want to install your own jdk use the following documentation:


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.