check_snmp uptime no longer working

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

check_snmp uptime no longer working

Post by WillemDH »

This morning, we got several service check timeouts for several network devices. Seems the check_smp, with command $USER1$/check_snmp -H $HOSTADDRESS$ $ARG1$ and $ARG1$ = -o sysUpTime.0 -C nagios -P 2c stopped working.

When trying from command line the check command does'nt work either.
When trying to access the network devices with a mib browser, I can clearly see the uptime oid.

Anyone got an idea what might be going on?

Also it seems the CCM page sometimes won't load. There is only a white screen. The only thing that helps is a service httpd restart, but after some time it's broken again..

I just did some testing and I think these two problems are related. When I do a httpd restart, then test the uptime for a network device, the CCM stops working.. :(
Nagios XI 5.8.1
https://outsideit.net
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

Re: check_snmp uptime no longer working

Post by WillemDH »

Ok, I think I must have messed up my mib files or snmptt or something, although the only thing I did was adding two mib files that don't have anything to do with these network devices..

it seems when I replace sysUpTime.0 with the actual oid of sysUpTime.0, it works...

COMMAND: /usr/local/nagios/libexec/check_snmp -H 10.54.20.33 -o .1.3.6.1.2.1.1.3.0 -C nagios -P 2c
OUTPUT: SNMP OK - Timeticks: (95801993) 11 days, 2:06:59.93 |

So how should I proceed in restoring this situation, so sysUpTime.0 works again?
Nagios XI 5.8.1
https://outsideit.net
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: check_snmp uptime no longer working

Post by abrist »

You may have two mibs that both have sysUpTime.0 defined.
WillemDH wrote:So how should I proceed in restoring this situation, so sysUpTime.0 works again?
The only option would be to remove the offending mib or just use the oids.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

Re: check_snmp uptime no longer working

Post by WillemDH »

Ok, I deleted the two mib files I added, restarted the snmptt, snmpd and snmptrapd services and everything seems to work again. Does this mean I have to check every mib I add to see if there are some duplicate oids? Isn't there some uptime oid in a lot of mibs?
Nagios XI 5.8.1
https://outsideit.net
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

Re: check_snmp uptime no longer working

Post by WillemDH »

The problem mib is CISCO-CCM-MIB.my, that contains oid's for our Cisco Callmanager. In fact when I retried adding it, and executing an addmib, I get a lot of errors like these:

Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneName ::= { ccmPhoneEntry 20 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneProtocol ::= { ccmPhoneEntry 19 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneProductTypeIndex ::= { ccmPhoneEntry 18 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneTimeLastStatusUpdt ::= { ccmPhoneEntry 17 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneStatusReason ::= { ccmPhoneEntry 16 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneInetAddress ::= { ccmPhoneEntry 15 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneInetAddressType ::= { ccmPhoneEntry 14 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneDevicePoolIndex ::= { ccmPhoneEntry 13 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneTimeLastError ::= { ccmPhoneEntry 12 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneLastError ::= { ccmPhoneEntry 11 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneLoadID ::= { ccmPhoneEntry 10 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneE911Location ::= { ccmPhoneEntry 9 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneTimeLastRegistered ::= { ccmPhoneEntry 8 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneStatus ::= { ccmPhoneEntry 7 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneIpAddress ::= { ccmPhoneEntry 6 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneUserName ::= { ccmPhoneEntry 5 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneDescription ::= { ccmPhoneEntry 4 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneType ::= { ccmPhoneEntry 3 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhonePhysicalAddress ::= { ccmPhoneEntry 2 }
Cannot adopt OID in CISCO-CCM-MIB: ccmPhoneIndex ::= { ccmPhoneEntry 1 }
Unknown object identifier: CISCO-CCM-MIB::ccmGatewayFailedReason

Anyone already got something like this? In fact I am doing an snmp get on .1.3.6.1.4.1.9.9.156.1.5.5.0 to get the number of registered phones. I get the value, but another problem I have is that the performance graph doesn't show any information. I added a ping image to show what I can see in the graph. As the returned value of .1.3.6.1.4.1.9.9.156.1.5.5.0 is 148 at the moment, I was hoping to see a graph of how many registered telephones we have over time. Any tips to get this graph working?
You do not have the required permissions to view the files attached to this post.
Nagios XI 5.8.1
https://outsideit.net
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: check_snmp uptime no longer working

Post by abrist »

What is the full command and service check you are using for the number of registered phones? The check may not be returning performance data . . .
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

Re: check_snmp uptime no longer working

Post by WillemDH »

The full command would be this:

$USER1$/check_snmp -H $HOSTADDRESS$ $ARG1$
$ARG1$ = -o ".1.3.6.1.4.1.9.9.156.1.5.5.0" -C nagios -P 2c

I already tried without ", but still the same problem
Nagios XI 5.8.1
https://outsideit.net
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: check_snmp uptime no longer working

Post by sreinhardt »

The command looks fine, could you post the output as returned from the command above. I want to be sure that check_snmp is returning perfdata for you, not just a return value.
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.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: check_snmp uptime no longer working

Post by lmiltchev »

Run the following command and show us the output:

Code: Select all

/usr/local/nagios/libexec/check_snmp -H <your_host_IP_address> -o ".1.3.6.1.4.1.9.9.156.1.5.5.0" -C nagios -P 2c
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

Re: check_snmp uptime no longer working

Post by WillemDH »

Hello, this is the output:

/usr/local/nagios/libexec/check_snmp -H server_hostname -o ".1.3.6.1.4.1.9.9.156.1.5.5.0" -C nagios -P 2c
SNMP OK - 146 | iso.3.6.1.4.1.9.9.156.1.5.5.0=146c
Nagios XI 5.8.1
https://outsideit.net
Locked