Bug 312321

Summary: 'Java Toolset Configuration' utility does not detect any installed Java package
Product: [Fedora] Fedora Reporter: Joachim Frieben <jfrieben>
Component: system-switch-javaAssignee: Thomas Fitzsimmons <fitzsim>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: rawhide   
Target Milestone: ---   
Target Release: ---   
Hardware: noarch   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-10-02 18:23:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Joachim Frieben 2007-09-29 13:38:55 UTC
Description of problem:
The 'Java Toolset Configuration' utility does not detect any Java package even
though several are installed.

Version-Release number of selected component (if applicable):
system-switch-java-1.1.1-1.fc8

How reproducible:
Always.

Steps to Reproduce:
1. Launch 'Java Toolset Configuration'.
  
Actual results:
A popup windows appears reporting:
 No supported Java packages were found.  A supported Java package is one
   that installs a file of the form:
 /usr/lib/jvm/jre-$version-$vendor/bin/java
 For example, java-1.4.2-gcj-compat is a supported package because it
   installs:
 /usr/lib/jvm/jre-1.4.2-gcj/bin/java

Expected results:
'Java Toolset Configuration' utility allows to select the default Java toolset
for the system.

Additional info:
Several Java packages are installed. In particular, the content of /usr/lib/jvm
reads:
java@                        java-gcj@       jre-1.7.0-icedtea@
java-1.5.0@                  jre@            jre-gcj@
java-1.5.0-gcj@              jre-1.5.0@      jre-icedtea@
java-1.5.0-gcj-1.5.0.0/      jre-1.5.0-gcj@
java-1.7.0-icedtea-1.7.0.0/  jre-1.7.0@

Comment 1 Thomas Fitzsimmons 2007-10-01 17:02:37 UTC
This error can also mean that system-switch-java cannot open
/var/lib/alternatives/java.  Can you confirm this is not the case?

Comment 2 Joachim Frieben 2007-10-02 13:17:24 UTC
(In reply to comment #1)
For an ordinary user, 'grep /usr/lib/jvm/jre /var/lib/alternatives/java' returns:

  /usr/lib/jvm/jre
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/java
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/keytool
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/orbd
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/pack200
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/policytool
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/rmid
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/rmiregistry
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/servertool
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/tnameserv
  /usr/lib/jvm/jre-1.7.0-icedtea/bin/unpack200
  /usr/lib/jvm/jre-1.7.0-icedtea
  /usr/lib/jvm/jre-1.5.0-gcj/bin/java
  /usr/lib/jvm/jre-1.5.0-gcj/bin/keytool
  /usr/lib/jvm/jre-1.5.0-gcj/bin/rmiregistry
  /usr/lib/jvm/jre-1.5.0-gcj

I have no idea wether 'system-switch-java' might encounter problems with this
file beyond that, but even launching it from the command line, no error message
is spawned to the shell indicating problems of any kind.
Moreover, 'SELinux' is enabled but in permissive mode, so this should not make a
difference either.

Comment 3 Thomas Fitzsimmons 2007-10-02 18:23:55 UTC
Fixed in system-switch-java-1.1.2-1.fc8.  An unhandled exception was being
thrown if either java-1.7.0-icedtea-plugin or java-1.7.0-icedtea-javadoc was not
installed.  Thanks for reporting.