Doesn't use java picked trough debian alternatives.

Bug #673836 reported by Roman A. Taycher
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tomcat6 (Ubuntu)
Opinion
Low
Unassigned

Bug Description

Binary package hint: tomcat6

I may be wrong and maybe this is done to keep tomcat configuration as cross
distro as possible but from /ect/init.d/tomcat6 it looks to my untrained eyes as
though instead of picking java from debian alternatives system, it just picks the
 first of openjdk,sun java 6,sun java 5,ibm java that is installed.

Revision history for this message
Roman A. Taycher (rtaycher) wrote :

From /ect/init.d/tomcat6

# The first existing directory is used for JAVA_HOME (if JAVA_HOME is not
# defined in $DEFAULT)
JDK_DIRS="/usr/lib/jvm/java-6-openjdk /usr/lib/jvm/java-6-sun /usr/lib/jvm/java-1.5.0-sun /usr/lib/j2sdk1.5-sun /usr/lib/j2sdk1.5-ibm"

# Look for the right JVM to use
for jdir in $JDK_DIRS; do
    if [ -r "$jdir/bin/java" -a -z "${JAVA_HOME}" ]; then
        JAVA_HOME="$jdir"
    fi
done
export JAVA_HOME

James Page (james-page)
Changed in tomcat6 (Ubuntu):
importance: Undecided → Low
status: New → Triaged
Revision history for this message
Thierry Carrez (ttx) wrote :

This is by design... The alternatives system is there for users to pick what JVM to use when the user types "java" on the CLI, not really to select which JVM Tomcat6 should use. In particular, you might want something different in both scenarios.

The Tomcat6 JVM is set in /etc/default/tomcat6. If unspecified, it chooses the first available in the list you mentioned.

Changed in tomcat6 (Ubuntu):
status: Triaged → Opinion
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.