This article shows how to install and select multiple version's of JAVA in Ubuntu 14.04.
Before installing, first we need to know what are the available java and javac paths in Operating System. To find that run the below commands.
sudo update-alternatives --config java
sudo update-alternatives --config javac
To install a new java and javac paths, use the below commands.
sudo update-alternatives --install "/usr/bin/java" "javac" "/home/ajanthan/wso2/jdk1.8.0_91/bin/javac" 1
sudo update-alternatives --install "/usr/bin/java" "java" "/home/ajanthan/wso2/jdk1.8.0_91/bin/java" 1
To select a java and javac path currently available. Use the below commands and give the Selection No when prompted.
sudo update-alternatives --config java
sudo update-alternatives --config javac
No comments:
Post a Comment