lausser / check_nwc_health

nwc = network component. This plugin checks lots of aspects of routers, switches, wlan controllers, firewalls,.....
http://labs.consol.de/nagios/check_nwc_health
GNU General Public License v2.0
149 stars 88 forks source link

sysUpTime or sysDescr isn't detected properly #211

Closed mrgohin closed 3 years ago

mrgohin commented 5 years ago

Hello,

It seems like that on some devices the sysDescr parsing / detection is failing.

On a HP 5400R nwc_health is reporting for example:

# ./check_nwc_health --hostname * --community * --mode interface-usage --report short
UNKNOWN - got neither sysUptime nor sysDescr, is this snmp agent working correctly?

and with super verbose (correct me whatever the correct name is):

Fri Jul 12 10:27:17 2019: AUTOLOAD Classes::Device::check_messages

Fri Jul 12 10:27:17 2019: i know package Monitoring::GLPlugin::SNMP::MibsAndOids::MIB2MIB
Fri Jul 12 10:27:17 2019: cache: 1.3.6.1.2.1.1.3.0
Fri Jul 12 10:27:17 2019: i know package Monitoring::GLPlugin::SNMP::MibsAndOids::MIB2MIB
Fri Jul 12 10:27:17 2019: GET: MIB-2-MIB::sysUpTime (1.3.6.1.2.1.1.3) : 1415981744
Fri Jul 12 10:27:17 2019: i know package Monitoring::GLPlugin::SNMP::MibsAndOids::SNMPFRAMEWORKMIB
Fri Jul 12 10:27:17 2019: cache: 1.3.6.1.6.3.10.2.1.3.0
Fri Jul 12 10:27:17 2019: GET: SNMP-FRAMEWORK-MIB::snmpEngineTime (1.3.6.1.6.3.10.2.1.3.0) : <undef>
Fri Jul 12 10:27:17 2019: i know package Monitoring::GLPlugin::SNMP::MibsAndOids::SNMPFRAMEWORKMIB
Fri Jul 12 10:27:17 2019: cache: 1.3.6.1.6.3.10.2.1.3.0.0
Fri Jul 12 10:27:17 2019: GET: SNMP-FRAMEWORK-MIB::snmpEngineTime (1.3.6.1.6.3.10.2.1.3.0) : <undef>
Fri Jul 12 10:27:17 2019: i know package Monitoring::GLPlugin::SNMP::MibsAndOids::HOSTRESOURCESMIB
Fri Jul 12 10:27:17 2019: cache: 1.3.6.1.2.1.25.1.1
Fri Jul 12 10:27:17 2019: GET: HOST-RESOURCES-MIB::hrSystemUptime (1.3.6.1.2.1.25.1.1) : <undef>
Fri Jul 12 10:27:17 2019: i know package Monitoring::GLPlugin::SNMP::MibsAndOids::HOSTRESOURCESMIB
Fri Jul 12 10:27:17 2019: cache: 1.3.6.1.2.1.25.1.1.0
Fri Jul 12 10:27:17 2019: GET: HOST-RESOURCES-MIB::hrSystemUptime (1.3.6.1.2.1.25.1.1) : <undef>
Fri Jul 12 10:27:17 2019: i know package Monitoring::GLPlugin::SNMP::MibsAndOids::MIB2MIB
Fri Jul 12 10:27:17 2019: cache: 1.3.6.1.2.1.1.1.0
Fri Jul 12 10:27:17 2019: GET: MIB-2-MIB::sysDescr (1.3.6.1.2.1.1.1) : <undef>
Fri Jul 12 10:27:17 2019: sysUptime says:      up since: Tue Jan 29 12:10:19 2019 / 163d 21h 16m 57s
Fri Jul 12 10:27:17 2019: AUTOLOAD Classes::Device::check_messages

Fri Jul 12 10:27:17 2019: AUTOLOAD Classes::Device::override_opt

Fri Jul 12 10:27:17 2019: AUTOLOAD Monitoring::GLPlugin::Commandline::override_opt

Fri Jul 12 10:27:17 2019: AUTOLOAD Classes::Device::check_messages

Fri Jul 12 10:27:17 2019: AUTOLOAD Classes::Device::check_messages

Fri Jul 12 10:27:17 2019: AUTOLOAD Classes::Device::nagios_exit

UNKNOWN - got neither sysUptime nor sysDescr, is this snmp agent working correctly?

If I run a snmpwalk against the same switch:

# snmpbulkwalk -t 15 -r 20 -ObentU -v2c -c public * system
.1.3.6.1.2.1.1.1.0 = STRING: HP J9850A Switch 5406Rzl2, revision KB.16.08.0001, ROM KB.16.01.0006 (/ws/swbuildm/rel_yakima_qaoff/code/build/bom(swbuildm_rel_yakima_qaoff_rel_yakima))
.1.3.6.1.2.1.1.2.0 = OID: .1.3.6.1.4.1.11.2.3.7.11.160
.1.3.6.1.2.1.1.3.0 = 1454845543
.1.3.6.1.2.1.1.4.0 = STRING: *
.1.3.6.1.2.1.1.5.0 = STRING: *
.1.3.6.1.2.1.1.6.0 = STRING: *
.1.3.6.1.2.1.1.7.0 = INTEGER: *

I'd wish I could just provide a Pull Request, but I'm not aware of where this detection process is happening. My Guess is that GL Plugins got it hands on it...