Home Directory

Search Exchange

Search All Sites

Nagios Live Webinars

Let our experts show you how Nagios can help your organization.

Contact Us

Phone: 1-888-NAGIOS-1
Email: sales@nagios.com

Login

Remember Me

Directory Tree

Directory

jeffr680j

Reviews(1)
byjeffr680j, June 21, 2012
Hi all,

I can't wait to get this plugin working!, but for some reason (I can't get it working). I am assuming user error as it works via terminal. I set it to be executable, and I get a

(Return code of 127 is out of bounds - plugin may be missing) in nagios.

I have declared it in switch.cfg as:

#cisco Chassis temperature
define service{
use generic-service
host_name VPU Core
service_description Cisco Temps
check_command sgichk_cisco_chassis!-C read
}

I have declared it in commands.cfg as:
# 'check_enviro' command definition
define command{
command_name sgichk_cisco_chassis
command_line $USER1$/sgichk_cisco_chassis! -H $HOSTADDRESS$ $ARG1$
}

When I run it via terminal I get:

libexec# ./sgichk_cisco_chassis.pl -H 192.168.2.16 -C read
OK: All Environmental Sensors ok
SW#1, Sensor#1, GREEN = 31 = Normal
SW#2, Sensor#1, GREEN = 30 = Normal
Switch#1, Fan#1 = Normal
Switch#1, Fan#2 = Normal
Switch#2, Fan#1 = Normal
Sw1, PS1 Normal, RPS NotExist = Normal
Sw1, PS2 Normal, RPS NotExist = Normal
Sw2, PS1 Normal, RPS NotExist = Normal
Sw2, PS2 Normal, RPS NotExist = Normal
I am sorry. It looks like a great plugin, I just can't figure out how to get it to work. I would like to get it to report on each switch, in nagios 3.3.1. I don't see any specific documentation on how to use it.
Owner's reply

Hmmm, I think maybe you have an extra ! in your command_line? Here's what I'm using for my command config:

# Check ALL environmental sensors for a cisco device
define command{
command_name check-cisco-enviro
command_line $USER1$/sgichk_cisco_chassis.pl -H $HOSTADDRESS$ -C $USER3$ -2
}

The -2 option tells it to use snmp V2 (faster, especially over a WAN).