Sun
Changing Java Versions in Ubuntu
Submitted by Chadarius on Wed, 2008-10-08 10:22.I recently needed to bring up a java app that I hadn't used in quite some time. At least as long as before I had Kubntu 8.04 installed. Back then I was using Java 6 (1.6.x) as the default JRE on my latptop. Now however, the app was failing with all kinds of errors.
As with any OS that can use Java, just because you have a java version installed, doesn't mean that version is the one that is launched by default. I have Java-gcj, Java 5 and Java 6 all installed on my Kubuntu 8.04 laptop. Java-gcj was currently the default java version.
In Linux, the way the java default is setup is both elagent and confusing all at the same time (Linux in a nutshell if you ask me, and I love it!). In Linux the /usr/bin/java file is really just a link to the java version that you want to be the default. But /usr/bin/java links to another link to /etc/alternatives/java which in turn links to the actual java binary at /usr/lib/jvm/java-gcj/jre/bin/java.
»
- Chadarius's blog
- Login to post comments
- Read more
- 627 reads

