How to change the Java home variables for TIBCO LogLogic Compliance Manager in Linux

How to change the Java home variables for TIBCO LogLogic Compliance Manager in Linux

book

Article ID: KB0079346

calendar_today

Updated On:

Products Versions
TIBCO LogLogic Compliance Manager 2.1.0, 2.1.1

Description

If Java is updated or you have multiple versions of Java on the same server where Compliance Manager is hosted you need to edit a script within the Tomcat bin directory in order for Tomcat to start using the desired version of Java. A situation could be seen for example if Compliance Manager was upgraded from 2.1.0 to 2.1.1 and Java 1.6 is the currently installed version. This would cause the Tomcat server not to start in 2.1.1 because this version of Java is not compatible with the newer version of Tomcat in Compliance Manager 2.1.1. You would need to install either Java .1.7 or 1.8 and then update a script to ensure Tomcat can start with the supported version. The procedure below with detail what is needed to be performed.

Issue/Introduction

If Java is updated or you have multiple versions of Java on the same Linux server where Compliance Manager is hosted you need to edit a script within the Tomcat bin directory so that CM uses the proper Java instance.

Resolution

The Compliance Manager installation directory will contain a Tomcat directory. Within that is the bin directory containing a script called setenv.sh. This script holds the path to where Java is installed. That path will be the one pointing to the Java version that Compliance Managers uses to start Tomcat. The setenv.sh script is called by the catalina.sh script when the Tomcat service is started. Below is an example of a setenv.sh script that contains a path to the Java version used within the example setup:

#!/bin/sh
export JRE_HOME=/opt/loglogic/jre1.8.0_191/
export CATALINA_OPTS="-Xms128M -Xmx1280M"


The correct version of Java being used can be verified by running the version.sh script within the tomcat/bin directory. You will see the JRE_HOME path listed in the output like below:

[root@oracle12c bin]# ./version.sh
Using CATALINA_BASE:   /opt/loglogic/compliancemanager2.1.0/tomcat
Using CATALINA_HOME:   /opt/loglogic/compliancemanager2.1.0/tomcat
Using CATALINA_TMPDIR: /opt/loglogic/compliancemanager2.1.0/tomcat/temp
Using JRE_HOME:        /opt/loglogic/jre1.8.0_191/
Using CLASSPATH:       /opt/loglogic/compliancemanager2.1.0/tomcat/bin/bootstrap.jar:/opt/loglogic/compliancemanager2.1.0/tomcat/bin/tomcat-juli.jar
Server version: Apache Tomcat/8.0.43
Server built:   Mar 28 2017 14:42:59 UTC
Server number:  8.0.43.0
OS Name:        Linux
OS Version:     4.1.12-124.18.5.el7uek.x86_64
Architecture:   amd64
JVM Version:    1.8.0_191-b12
JVM Vendor:     Oracle Corporation


Once you have updated this variable in the script you can stop and start the Compliance Manager Tomcat service using:

service tomcatd_cm2.1.1 stop
service tomcatd_cm2.1.1 start


The Compliance Manager GUI will now be running via the desired version of Java configured within the setenv.sh script.

Note - Compliance Manager Tomcat will only use the Java path and version from the setenv.sh script regardless of what the java -version displays within the CLI.