Created
September 6, 2014 22:21
-
-
Save wavescholar/5f1cb490f9439ede7bc1 to your computer and use it in GitHub Desktop.
java alternatives setup Oracle on top of OpenJDK
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
-------------------------- | |
Swap between OpenJDK and Sun/Oracle Java JDK/JRE | |
alternatives --config java | |
alternatives --config javaws | |
alternatives --config libjavaplugin.so | |
alternatives --config libjavaplugin.so.x86_64 | |
alternatives --config javac | |
Post-Installation Setup | |
Add JAVA_HOME environment variable to /etc/profile file or $HOME/.bash_profile | |
Java JDK and JRE latest version (/usr/java/latest) | |
You can make a simbolic link from your Java JDK to that directory, so it makes it easier to handle several versions of java | |
# export JAVA_HOME JDK/JRE | |
export JAVA_HOME="/usr/java/latest" | |
Java JDK and JRE absolute version (/usr/java/jdk1.7.0_09) or other version | |
# export JAVA_HOME JDK | |
export JAVA_HOME="/usr/java/jdk1.7.0_09" | |
# export JAVA_HOME JRE # | |
export JAVA_HOME="/usr/java/jre1.7.0_09" | |
--------------------------------------- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment