Page 1 of 1

Switch monitoring error

Posted: Mon Mar 11, 2013 12:20 pm
by fugitive
I'm running into issues monitoring my cisco gear.

I'm attempting to just get the link status for single interface (interface 6) on cisco catalyst switch.

I receive this error in nagios:

External command error: Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: RFC1213-MIB::ifOperStatus.6

Can you point me in a direction. I seem to be spinning my wheels on this.

Re: Switch monitoring error

Posted: Mon Mar 11, 2013 1:07 pm
by abrist
Can you get link status on any other interface? Can you snmpwalk the device? Is the MIB/oid listed in the walk? Is snmp enabled on the cisco device?

Re: Switch monitoring error

Posted: Mon Mar 11, 2013 1:44 pm
by fugitive
After doing this:

/usr/local/nagios/etc/objects# snmpwalk -v2c -c public 10.100.0.1 | grep "ifOperStatus*"

Found out ports are listed like this: = port 6
IF-MIB::ifOperStatus.10106 = INTEGER: up(1)

Re: Switch monitoring error

Posted: Mon Mar 11, 2013 2:00 pm
by abrist
Does the check work now with the MIB:

Code: Select all

IF-MIB::ifOperStatus.10106
?

Re: Switch monitoring error

Posted: Mon Mar 11, 2013 2:39 pm
by fugitive
Works correctly with this MIB

check_command check_snmp!-C public -o ifOperStatus.10106 -r 1 -m RFC1213-MIB

Interface Gi0/6
OK 03-11-2013 15:37:04 0d 0h 41m 44s 1/3 SNMP OK - up(1)

Re: Switch monitoring error

Posted: Mon Mar 11, 2013 2:49 pm
by abrist
Great! Are we lock-ready or do you have any other questions pertaining to your cisco device and snmp?

Re: Switch monitoring error

Posted: Tue Mar 12, 2013 7:28 am
by fugitive
Ready for now. Thanks

Though down the road I hope to integrate an Cisco ASA and a Cisco Router and lots of other things.

Re: Switch monitoring error

Posted: Tue Mar 12, 2013 9:24 am
by slansing
Great, let us know when you need help!