Default Java bin symlink points to specific version instead of default-java

Asked by Matt McCann

I am using Ubuntu 12.04. As per default, I had openjdk-6-jre installed. After installing openjdk-7-jre via Synaptic, I realized none of the symlinks updated to the new version (which in my humble opinion should happen automatically to improve usability for non-technical users, especially considering the different version are backwards compatible).

When going to manually update the symlinks, I discovered that /usr/bin/java points to /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java. It would seem to me that it would make more sense for it to point at /usr/lib/jvm/default-java/jre/bin/java instead.

I'm posting this as a question because this seems like such an obvious bug that there must be some logic behind the /usr/bin/java link not utilizing the version symlink structure in the /usr/lib/jvm folder. Please enlighten me regarding the logic.

Thanks!

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu openjdk-7 Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Matt McCann (mccann-matt) said :
#1

I need to clarify something I missed about the symlink structure (thanks to Python being so useful and tracing symlinks for me). The actual structure is:

/usr/bin/java -> /etc/alternatives/java -> /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java

All this changes is the /etc/alternatives/java symlink is suspect now rather than /usr/bin/java symlink.

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#2

I suggest you report a bug. If you have Oracle Java, why would it need to point to openjdk at all? Why not point it to the Oracle Java. There is a PPA for Oracle Java makes all Java point to itself (handy)

Can you help with this problem?

Provide an answer of your own, or ask Matt McCann for more information if necessary.

To post a message you must log in.