Issues on running check_jmx

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
stecino
Posts: 248
Joined: Thu Mar 14, 2013 4:42 pm

Issues on running check_jmx

Post by stecino »

Running into this type of error when running on the NRPE client. NRPE is configured and running

[root@vmstageapp01 libexec]# ./check_nrpe -H localhost
NRPE v2.13

[root@vmstageapp01 libexec]# ./check_jmx -U service:jmx:rmi:///jndi/rmi://localhost:11099/jmxrmi -O java.lang:type=Memory -A HeapMemoryUsage -K used -I HeapMemoryUsage -J used -w 5476083302 -c 5798205849
Exception in thread "main" java.lang.NoClassDefFoundError: org/nagios/JMXQuery
Caused by: java.lang.ClassNotFoundException: org.nagios.JMXQuery
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find the main class: org.nagios.JMXQuery. Program will exit.
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Issues on running check_jmx

Post by sreinhardt »

What permissions do you have on the jmxquery.jar? It seems that most issues similar to yours that the nagios user does not have ownership of the file.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
Locked