activemq launched from QSH cannot find its pid
QSH CMD('/QOpenSys/pkgs/bin/bash -c "/QOpenSys/pkgs/bin/activemq start >> /home/driveway/jwoehr/amqfoo.txt"')
results in …
$ cat amqfoo.txt
INFO: Loading '/QOpenSys/pkgs/lib/activemq//bin/env'
INFO: Using java '/QOpenSys/usr/bin/java'
INFO: Starting - inspect logfiles specified in logging.properties and log4j.properties to get details
INFO: pidfile created : '/QOpenSys/pkgs/lib/activemq//data/activemq.pid' (pid '')
… with the result that …
$ activemq stop
… will no longer work as the pid file is empty.
Variations of the invocation from QSH QP2SHELL etc. with various shell syntax all fail in the exact same, including changing the shebang in the activemq launcher script /QOpenSys/pkgs/bin/activemq
Comments (5)
-
reporter -
reporter Oops, doesn’t work. Writes a PID to the pid file but it’s the wrong pid. Sigh.
-
It’s something related to process groups when run non-interactively, I think. Even a
ps
command shows an empty list with no arguments (which is what’s causing this AMQ issue).Will look into a workaround
-
I believe this should work with the new early-access Java 11 RPM.
Please install and try openjdk to verify, by setting the JAVA_HOME environment variable to/QOpenSys/pkgs/lib/jvm/openjdk-11
Also, note the caveats documented here. This is for early access only: https://bitbucket.org/ibmi/opensource/src/master/docs/java11/JAVA11_EARLY_ACCESS.md
-
- changed status to resolved
This is a permanent restriction of ActiveMQ with JV1. Recommendation is to use RPM java for ActiveMQ deployments or to start via SSH
- Log in to comment
Found a workaround:
works.