Many times we would require to have older versions of java.Here are the steps install java 5 on Ubuntu 11.10
Run the following commands in a terminal
$ sudo add-apt-repository "deb http://us.archive.ubuntu.com/ubuntu/ hardy multiverse"
$ sudo add-apt-repository "deb http://us.archive.ubuntu.com/ubuntu/ hardy-updates multiverse"
$ sudo apt-get update
$ sudo apt-get install sun-java5-jdk
To confirm if successfully installed run.
$ sudo update-java-alternatives -l
To switch the Java version, run.
$ sudo update-java-alternatives -s java-1.5.0-sun
Then confirm if switched successfully, run.
$ java -version
Run the following commands in a terminal
$ sudo add-apt-repository "deb http://us.archive.ubuntu.com/ubuntu/ hardy multiverse"
$ sudo add-apt-repository "deb http://us.archive.ubuntu.com/ubuntu/ hardy-updates multiverse"
$ sudo apt-get update
$ sudo apt-get install sun-java5-jdk
To confirm if successfully installed run.
$ sudo update-java-alternatives -l
To switch the Java version, run.
$ sudo update-java-alternatives -s java-1.5.0-sun
Then confirm if switched successfully, run.
$ java -version
Comments
Post a Comment