Re: check_jmx plugin works on client but not on nagios serve
Posted: Tue Nov 21, 2017 5:44 pm
@jh129666, Sigle quotes are not allowed in NRPE. You may try to enable "nasty characters". On the remote server open nrpe.cfg and enable the following arguments:
When that's done restart NRPE and try passing the command with single and double quotes one more time. But if that doesn't work I recommend hardcoding the base part of the command in nrpe.cfg and only passing the argument that is actually changing. Just like so:
Or
The only condition is that name='"activemq"' stays defined in nrpe.cfg
Code: Select all
allow nasty characters=true
allow nasty characters=trueCode: Select all
command[check_jmx]=/usr/local/nagios/plugins/check_jmx -U service:jmx:rmi:///jndi/rmi://$ARG1$:1234/jmxrmi -O org.apache.camel:context=camel-1,type=components,name='"activemq"' -A StateCode: Select all
command[check_jmx]=/usr/local/nagios/plugins/check_jmx -U service:jmx:rmi:///jndi/rmi://$ARG1$/jmxrmi -O org.apache.camel:context=camel-1,type=components,name='"activemq"' -A State