[Bug 1107342] New: JAVA_HOME incorrectly set by /etc/profile.d/alljava.*
http://bugzilla.opensuse.org/show_bug.cgi?id=1107342 Bug ID: 1107342 Summary: JAVA_HOME incorrectly set by /etc/profile.d/alljava.* Classification: openSUSE Product: openSUSE Tumbleweed Version: Current Hardware: x86-64 OS: Other Status: NEW Severity: Normal Priority: P5 - None Component: Java Assignee: bnc-team-java@forge.provo.novell.com Reporter: mario.g.pavlov@gmail.com QA Contact: qa-bugs@suse.de Found By: --- Blocker: --- Created attachment 782101 --> http://bugzilla.opensuse.org/attachment.cgi?id=782101&action=edit Patches for both the Bourne shell and the C shell. If custom java (e.g. Oracle) is installed and used via the "alternatives system" then /etc/profile.d/alljava.* wouldn't set the correct JAVA_HOME. So the user is in a situation where they have all links pointing to their custom java but the JAVA_HOME env var is set to whatever OpenJDK was installed before that. This causes nasty issues with all sorts of java tools and applications. Please find attached patches that add support for determining JAVA_HOME via /etc/alternatives/java if exists. The patches were tested with the latest Tumbleweed as of this writing. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1107342 Mario Pavlov <mario.g.pavlov@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |1043388 -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1107342 http://bugzilla.opensuse.org/show_bug.cgi?id=1107342#c1 Michael Pujos <pujos.michael@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |pujos.michael@gmail.com --- Comment #1 from Michael Pujos <pujos.michael@gmail.com> --- alljava scripts in /etc/profile.d do indeed not honor the current alternative set for Java, which leads to unexpected results with Java tools making use of JAVA_HOME to determine which JRE/JDK to use. It would be great to have this fixed officially, as this is confusing. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1107342 http://bugzilla.opensuse.org/show_bug.cgi?id=1107342#c2 --- Comment #2 from Mario Pavlov <mario.g.pavlov@gmail.com> --- Michael, thanks for your comment. Did you have a chance to try out the patches? -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1107342 http://bugzilla.opensuse.org/show_bug.cgi?id=1107342#c3 asf <1000Hz.radiowave@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |1000Hz.radiowave@gmail.com --- Comment #3 from asf <1000Hz.radiowave@gmail.com> --- After installing java-16-openjdk the JAVA_HOME is pointed to /usr/lib64/jvm/java Which simply doesn't exist. Shouldn't it point to the /usr/lib64/jvm/jre? -- You are receiving this mail because: You are on the CC list for the bug.
participants (2)
-
bugzilla_noreply@novell.com
-
bugzilla_noreply@suse.com