I have setup a cold standby server and restored from backup. One of the mibs that is installed is not working. I see the mib in Admin->Manage MIBs and the mib does exists in /usr/share/snmp/mibs. When I run the snmp command I get
/usr/local/nagios/libexec/check_snmp -v -H x.x.x.x -p 161 -o ENTITY-SENSOR-MIB::entPhySensorValue.100006001 -C <community> -P 2c -w 450 -c 500
/bin/snmpget -Le -t 3 -r 5 -m ALL -v 2c [context] [authpriv] x.x.x.x:161 ENTITY-SENSOR-MIB::entPhySensorValue.100006001
External command error: MIB search path: /root/.snmp/mibs:/usr/share/snmp/mibs
Cannot find module (ENTITY-SENSOR-MIB): At line 0 in (none)
ENTITY-SENSOR-MIB::entPhySensorValue.100006001: Unknown Object Identifier
Is there configuration outside of nagiosxi I need to do after the initial restore?
Cold Standby SNMP
Re: Cold Standby SNMP
It should work if the mib is there, is that check failing if you run it from the CLI through an SSH session?
What is the output of this command?
What the permissions on the mib file?
What is the output of this command?
Code: Select all
grep 'ENTITY-SENSOR-MIB DEF' /usr/share/snmp/mibs/*
Code: Select all
ls -l /usr/share/snmp/mibs/themibfile.ext
-
- Posts: 131
- Joined: Wed Feb 20, 2019 3:46 pm
Re: Cold Standby SNMP
The output I posted is from an ssh session.
Here is the grep output.
[root@z2-nms-1 mibs]# grep -r 'ENTITY-SENSOR-MIB DEF' /usr/share/snmp/mibs/*
/usr/share/snmp/mibs/ARISTA-ENTITY-SENSOR-MIB.txt:ARISTA-ENTITY-SENSOR-MIB DEFINITIONS ::= BEGIN
/usr/share/snmp/mibs/ENTITY-SENSOR-MIB.mib:ENTITY-SENSOR-MIB DEFINITIONS ::= BEGIN
[root@z2-nms-1 mibs]#
Here is the permissions for the mib file.
[root@z2-nms-1 mibs]# ls -l /usr/share/snmp/mibs/ENTITY-SENSOR-MIB.mib
-rw-rw-r-- 1 root nagios 16710 Feb 17 16:22 /usr/share/snmp/mibs/ENTITY-SENSOR-MIB.mib
[root@z2-nms-1 mibs]#
Here is the grep output.
[root@z2-nms-1 mibs]# grep -r 'ENTITY-SENSOR-MIB DEF' /usr/share/snmp/mibs/*
/usr/share/snmp/mibs/ARISTA-ENTITY-SENSOR-MIB.txt:ARISTA-ENTITY-SENSOR-MIB DEFINITIONS ::= BEGIN
/usr/share/snmp/mibs/ENTITY-SENSOR-MIB.mib:ENTITY-SENSOR-MIB DEFINITIONS ::= BEGIN
[root@z2-nms-1 mibs]#
Here is the permissions for the mib file.
[root@z2-nms-1 mibs]# ls -l /usr/share/snmp/mibs/ENTITY-SENSOR-MIB.mib
-rw-rw-r-- 1 root nagios 16710 Feb 17 16:22 /usr/share/snmp/mibs/ENTITY-SENSOR-MIB.mib
[root@z2-nms-1 mibs]#
Re: Cold Standby SNMP
Does this work?
I downloaded to my system and then tested and it finds it properly.
I know it sounds dumb, but try doing this:
There is a mib index file that may not be updated and I think one of those will update it.
Then try the command again:
Code: Select all
/usr/local/nagios/libexec/check_snmp -v -H x.x.x.x -p 161 -o ENTITY-SENSOR-MIB::entPhySensorValue.100006001 -C <community> -P 2c -w 450 -c 500 -m ENTITY-SENSOR-MIB
I know it sounds dumb, but try doing this:
Code: Select all
service snmpd restart
service snmptrapd restart
snmpwalk -v 2c -c 'yourcommunity' 192.168.X.X:161 -m ENTITY-SENSOR-MIB ENTITY-SENSOR-MIB::entPhySensorValue.100006001
Then try the command again:
Code: Select all
/usr/local/nagios/libexec/check_snmp -v -H x.x.x.x -p 161 -o ENTITY-SENSOR-MIB::entPhySensorValue.100006001 -C <community> -P 2c -w 450 -c 500
-
- Posts: 131
- Joined: Wed Feb 20, 2019 3:46 pm
Re: Cold Standby SNMP
Thank you for your assistance.
Still got the same results from the commands you sent.
This is a standby server that was restored using the production server backup. The check does work correctly on production. I think I missed something in snmp setup but cannot find it. Everything I have tried hasn't worked.
Still got the same results from the commands you sent.
This is a standby server that was restored using the production server backup. The check does work correctly on production. I think I missed something in snmp setup but cannot find it. Everything I have tried hasn't worked.
-
- Posts: 131
- Joined: Wed Feb 20, 2019 3:46 pm
Re: Cold Standby SNMP
I forgot to mention the new standby is a clean install of centos7 and then did a restore using the backup file produced by nagiosxi in the local backup archives.
-
- Posts: 5324
- Joined: Wed Aug 22, 2018 4:39 pm
- Location: saint paul
Re: Cold Standby SNMP
HI,
Best Regards,
Benjamin
Honestly, not sure why this is not working for you. I'm going to reach out to a few Sean and the rest of the team and follow up shortly with you.I forgot to mention the new standby is a clean install of centos7 and then did a restore using the backup file produced by nagiosxi in the local backup archives.
Best Regards,
Benjamin
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
- Posts: 5324
- Joined: Wed Aug 22, 2018 4:39 pm
- Location: saint paul
Re: Cold Standby SNMP
Hi,
After discussing this with the team, we feel it would be best to open a ticket for the issue and we'll get a remote session setup to debug this further.
To open a support ticket, go to:
https://support.nagios.com/tickets/
and reference this post.
Thanks!
Benjamin
After discussing this with the team, we feel it would be best to open a ticket for the issue and we'll get a remote session setup to debug this further.
To open a support ticket, go to:
https://support.nagios.com/tickets/
and reference this post.
Thanks!
Benjamin
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Be sure to check out our Knowledgebase for helpful articles and solutions!