null results with check_iseries.pl

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
mariof
Posts: 19
Joined: Thu May 20, 2010 5:01 am

null results with check_iseries.pl

Post by mariof »

Hi,

When I run the check_iseries.pl from the command line (as the nagios user), I get an expected result:

check_iseries OK - Current ASP used (%): 65.75 | total=564519763968b;; usage=371182460928b;;

When I run the same command within XI, i get a "null" result.

The script makes use of the Nagios::Plugin, but I was wondering is XI understands the output from the nagios_exit subroutine.

Any information will be helpful - my perl is very rusty.

Thanks in advance

Mario
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: null results with check_iseries.pl

Post by lmiltchev »

Mario,

Can you post (place a screenshots) of your service and command definitions of this check in Nagios XI?
Be sure to check out our Knowledgebase for helpful articles and solutions!
mariof
Posts: 19
Joined: Thu May 20, 2010 5:01 am

Re: null results with check_iseries.pl

Post by mariof »

Hi,
here are the screen shots - nothing very remarkable, and the command line uses the same syntax.
nagios_iseries_command.png
You do not have the required permissions to view the files attached to this post.
mariof
Posts: 19
Joined: Thu May 20, 2010 5:01 am

Re: null results with check_iseries.pl

Post by mariof »

I've also checked the nagios logs but all i can see is that the result is null. Is there a way of debugging this. using the -v option didn't help me.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: null results with check_iseries.pl

Post by lmiltchev »

mariof,

You can try adding "perl" in the path (in your command definition), so for example, instead of:

Code: Select all

$USER1$/check_iseries.pl -H ...
you will have:

Code: Select all

/usr/bin/perl $USER1$/check_iseries.pl -H ...
or

Code: Select all

/usr/bin/perl /usr/local/nagios/libexec/check_iseries.pl -H ...
Can you also post your actual check command that you use from the command line? You've shown only the check results in your first post.
Be sure to check out our Knowledgebase for helpful articles and solutions!
mariof
Posts: 19
Joined: Thu May 20, 2010 5:01 am

Re: null results with check_iseries.pl

Post by mariof »

Hi,

Here is the command with the community string removed (run as the nagios user from /usr/local/nagios/libexec):

./check_iseries.pl -H servername -c <string> -t 20 -o asp -w 80
check_iseries OK - Current ASP used (%): 65.77 | total=564519763968b;; usage=371295047680b;;

I also tried both your suggested changes to the command and it still didn't work. I think XI doesn't like the output from the command, but I can't tell for sure.
Last edited by mariof on Wed Dec 21, 2011 10:45 am, edited 1 time in total.
mariof
Posts: 19
Joined: Thu May 20, 2010 5:01 am

Re: null results with check_iseries.pl

Post by mariof »

PS - i do use other snmp based perl scripts successfully. check_snmp_storage.pl and check_snmp_load.pl for example.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: null results with check_iseries.pl

Post by lmiltchev »

mariof,

We will do some more digging and will get back to you when/if we find a solution.
Be sure to check out our Knowledgebase for helpful articles and solutions!
mariof
Posts: 19
Joined: Thu May 20, 2010 5:01 am

Re: null results with check_iseries.pl

Post by mariof »

Thank you.

Not sure if this helps nor not, but neither check_snmp_load.pl or check_snmp_storage.pl use Nagios::Plugin
mariof
Posts: 19
Joined: Thu May 20, 2010 5:01 am

Re: null results with check_iseries.pl

Post by mariof »

i fixed it!
i should have checked before, but i needed to change:
use lib "/usr/lib/nagios/plugins";
to
use lib "/usr/local/nagios/libexec";
Locked