Subject: | jmx4perl : issue on check_jmx4perl |
Date: | Wed, 10 Dec 2014 13:19:54 +0000 |
To: | "bug-jmx4perl [...] rt.cpan.org" <bug-jmx4perl [...] rt.cpan.org> |
From: | WINGEL Mathieu <Mathieu.WINGEL [...] sihm.fr> |
Hello,
I'm using check_jmx4perl version 1.10 on CentOs 5.10, perl 5.8.8
When I use the following command, it should answer with a critical :
[nagios@FPS37ETU1 ]# check_jmx4perl --url http://localhost:8080/jolokia --name test --value com.bea:Name=portail_ppd1,Type=ServerRuntime/OverallHealthState/State --warning 1 --critical 0 --target service:jmx:t3://mhm37ppd1:7011/jndi/weblogic.management.mbeanservers.runtime --target-user=monitor --target-password=XXXXX
OK - test : Value 0 in range | test=0;1;0
My need is to raise a critical when the result is different than 0. According to the doc on cpan, it's better to convert the result in a string and add a leading '!' character to do so.
But to highlight the problem, I just check against 0.
Still, no critical answer is raised:
[nagios@FPS37ETU1 ]# check_jmx4perl --url http://localhost:8080/jolokia --name test --value com.bea:Name=portail_ppd1,Type=ServerRuntime/OverallHealthState/State --string --warning 1 --critical 0 --target service:jmx:t3://mhm37ppd1:7011/jndi/weblogic.management.mbeanservers.runtime --target-user=monitor --target-password=XXXXXX --perfdata on
OK - test : '0' as expected | test=0;1;0
I have the same result using a similar mbean : com.bea:Name=portail_ppd1,Type=ServerRuntime/HealthState/State. However, the check works well on simple attributes with an integer type. Maybe the ckeck doesn't work the same way when attributes are complex ( classes ) as it's the case here.
Thanks for your help.
Cordialement,
Mathieu Wingel
Ingénieur Production
Direction Production
[cid:image003.jpg@01CE7F11.9BB11B50]
41 rue Fabienne Landy
37700 Saint Pierre des Corps
Tél. 02 47 46 58 87
mathieu.wingel@sihm.fr<mailto:prenom.nom@sihm.fr>
En harmonie avec votre santé