Endevor web services - "CEE3501S The module libjvm.so was not found" in Tomcat STC
search cancel

Endevor web services - "CEE3501S The module libjvm.so was not found" in Tomcat STC

book

Article ID: 259402

calendar_today

Updated On:

Products

Endevor

Issue/Introduction

Startup of JVM for the Tomcat server to be used for Endevor web services might fail with

CEE3501S The module libjvm.so was not found.                                                                                      
From entry point JzosVM::initializeVMArgs() at compile unit offset +00000094 at entry offset +00000094 at address 2E90622C.

How to deal with this situation?

Environment

Release : 19.0

Cause

File libjvm.so is the main program of the Java VM. The program that intends to build the JVM (in the case of the Tomcat server, the IBM batch launcher) tries to invoke this library to start the JVM.

IBM LE (Language Environment) tries to load this library from each and every of the folders named in the LIBPATH environment variable.

This variable is exported by the script specified in STDENV DD in the JCL that starts the Tomcat server

The script is customized by the install scripts based on what is specified in file ENWSInstallOptions.properties

The folders related to Java are located from the base folder named in JAVA_HOME parameter

Resolution

It is important to locate the right JAVA_HOME folder, specify it in the properties file and run the install script. This way, the script found in STDENV DD will name the right folders in variable LIBPATH

The installation of Java places symbolic links in folder /usr/lpp/java that point to the folders where the JVMs  reside. They may be found opening an Unix shell session via TSO OMVS command. For example:

$ cd /usr/lpp/java
$ ls -l
total 0
lrwxrwxrwx   1 SYSTEM   GROUP123      40 MON  D YYYY J11.0 -> /XXX/java31bt/v11
r0m0/XXX/XXX/java/J11.0
lrwxrwxrwx   1 SYSTEM   GROUP123      44 MON  D YYYY J11.0_64 -> /XXX/java64bt/
v11r0m0/XXX/XXX/java/J11.0_64/
lrwxrwxrwx   1 SYSTEM   GROUP123      38 MON  D  YYYY J8.0 -> /XXX/java31bt/v8r0
m0/XXX/XXX/java/J8.0
lrwxrwxrwx   1 SYSTEM   GROUP123      42 MON  D  YYYY J8.0_64 -> /XXX/java64bt/v
8r0m0/XXX/XXX/java/J8.0_64/
$

In theory, any of the above folders (/XXX/XXXjava/J11.0, /XXX/XXX/java/J11.0_64 and so on) is candidate to be used for the JAVA_HOME specification. However, the recommendation is to use only the Java v8 folders. It is important to use the right version (31-bit or 64-bit)

It is possible to further test whether the selected folder contains a working Java environment by using it to run the sample 'HelloWorld' class. For example, still in the Unix shell session:

$ export JAVA_HOME=/usr/lpp/java/J8.0_64
$ $JAVA_HOME/bin/java -version
java version "1.8.0_331"
Java(TM) SE Runtime Environment (build 8.0.7.10 - pmz6480sr7fp10-20220505_01(SR7
 FP10))
IBM J9 VM (build 2.9, JRE 1.8.0 z/OS s390x-64-Bit Compressed References 20220427
_27745 (JIT enabled, AOT enabled)
OpenJ9   - b15041a
OMR      - 3671a9f
IBM      - 1b0232b)
JCL - 20220504_01 based on Oracle jdk8u331-b09
$ $JAVA_HOME/bin/java -cp $JAVA_HOME HelloWorld
Hello World
$

File libjvm.so is present at several locations below the Java home folder. For example:

$ cd /XXX/XXX/java/J8.0_64
$ find . -name "libjvm.so"
./bin/j9vm/libjvm.so
./bin/classic/libjvm.so
./lib/XXXXX/j9vm/libjvm.so
./lib/XXXXX/default/libjvm.so
./lib/XXXXX/compressedrefs/libjvm.so
./lib/XXXXX/classic/libjvm.so
$

The exact file taken will depend on the LIBPATH setting passed to the JVM launcher via STDENV DD in the JCL. Note that the tailored STDENV script includes $JAVA_HOME/lib/XXXXX/classic (if using 64-bit Java) or $JAVA_HOME/lib/XXXX/classic (if using 31-bit Java) so the Java batch launcher should be able to find the library in LIBPATH