I have configured the check_jmx plugin for Nagios XI 5R1.0 and im getting this error on the NagiosXI service configuration -> Test Check Command.
Code: Select all
OUTPUT: JMX CRITICAL - java not foundIm posting the respective pics so anyone can help me.
This is the check_jmx script:
Code: Select all
#!/bin/sh
#
# Nagios JMX plugin.
#
JAVA_CMD=`which java`
if [ -z $JAVA_CMD ]
then
if [ -x $JAVA_HOME/bin/java ]
then
JAVA_CMD=$JAVA_HOME/bin/java
else
echo JMX CRITICAL - java not found.
exit 2
fi
fi
DIR=`dirname $0`
$JAVA_CMD -jar $DIR/check_jmx.jar "$@"
-kvaldez