Random Project

Not working

Tried with my nagios. It is running in a shell :

[nagios@myserver libexec]$ ./check_jmx -U service:jmx:rmi:///jndi/rmi://localhost:8999/jmxrmi -O “java.lang:type=Memory” -A HeapMemoryUsage -K used
JMX OK – HeapMemoryUsage.used = 605230312 | ‘HeapMemoryUsage used’=605230312;;;;

Not working with NRPE :

[nagios@myserver libexec]$ /usr/local/nagios/libexec/check_nrpe -H localhost -c check_jmx
NRPE: Unable to read output

in my nrpe.cfg :

command[check_jmx]=/usr/local/nagios/libexec/check_jmx -U service:jmx:rmi:///jndi/rmi://localhost:8999/jmxrmi -O “java.lang:type=Memory” -A HeapMemoryUsage -K used

I tried to add and differents kinds of “, but did not help. Any help would be great.