networkupstools / nut

The Network UPS Tools repository. UPS management protocol Informational RFC 9271 published by IETF at https://www.rfc-editor.org/info/rfc9271 Please star NUT on GitHub, this helps with sponsorships!
https://networkupstools.org/
Other
1.96k stars 348 forks source link

snmp-ups: time-intensive, futile attempts on non-existent/closed hosts #2134

Closed desertwitch closed 10 months ago

desertwitch commented 11 months ago

Reading yesterday's e-mail in the mailing list regarding a more or less imminent 2.8.1. release, I've decided to do some more testing. I've actually run into this problem (with a stuck system boot) before but haven't been able to trace it back to NUT and the SNMP driver.

At present the SNMP driver will start time-intensive, futile attempts to walk all kinds of MIBs on target hosts which are non-existent or do not even have a SNMP server listening. It will spend almost 4 minutes attemping SNMP operations on a dead/unresponsive target host before determining there's no connection possible or readable SNMP available and exiting.

This can (especially at system boot and with home-brewed startup scripts or badly implemented service environments) cause an unwanted delay in the whole boot routine, made much harder to trace by the fact that the snmp-ups driver itself does not present any log (only debug > 1) messages during these futile attempts until after it eventually gives up after the ~4 minutes (in my case).

Regarding upsdrvctl

I've - in particular - noticed this line in the log file (see below for full log):

Oct 28 02:47:16 Tower root: Startup timer elapsed, continuing...

Is it intended that upsdrvctl let the driver continue (which at present it does) after this point or should it kill it?

I have RTFM but I didn't find a startup timer option after which (I presume) the upsdrvctl should give up on a driver? If there isn't one - would this be a useful addition worth looking into for upsdrvctl?

Regarding snmp-ups

Not sure how, but possibly we can (sanity-)check if the host and/or SNMP ports are connectable on driver launch? If it isn't, then it seems it doesn't make much sense to run all these time- and network-intensive SNMP operations.

These are (debug level 4) log messages having to driver attempt to connect to a non-existent IP on my network:

Oct 28 02:46:31 Tower root:    0.000000#011[D1] debug level is '4'
Oct 28 02:46:31 Tower root:    0.001365#011[D1] Succeeded to become_user(root): now UID=0 GID=0
Oct 28 02:46:31 Tower root:    0.001415#011[D1] Saving PID 21139 into /var/run/nut/snmp-ups-ups.pid
Oct 28 02:46:31 Tower root:    0.001634#011[D1] SNMP UPS driver: entering upsdrv_initups()
Oct 28 02:46:31 Tower root:    0.001659#011[D2] SNMP UPS driver: entering nut_snmp_init(snmp-ups)
Oct 28 02:46:31 Tower root:    0.016486#011[D2] Setting SNMP retries to 5
Oct 28 02:46:31 Tower root:    0.016496#011[D2] Setting SNMP timeout to 1 second(s)
Oct 28 02:46:31 Tower root:    0.016625#011[D1] SNMP UPS driver: entering load_mib2nut(auto) to detect proper MIB for device [ups] (host 192.168.0.238)
Oct 28 02:46:31 Tower root:    0.016646#011[D2] load_mib2nut: trying the new match_sysoid() method with auto
Oct 28 02:46:31 Tower root:    0.016661#011[D3] load_mib2nut: trying the new match_sysoid() method: attempt #1
Oct 28 02:46:31 Tower root:    0.016676#011[D3] Entering nut_snmp_get_oid()
Oct 28 02:46:31 Tower root:    0.016690#011[D3] nut_snmp_get(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:31 Tower root:    0.016704#011[D3] nut_snmp_walk(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:31 Tower root:    0.016717#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:46:37 Tower root:    6.023129#011[D2] Can't get sysOID value (using nut_snmp_get_oid())
Oct 28 02:46:37 Tower root:    6.023145#011[D3] Entering nut_snmp_get_str()
Oct 28 02:46:37 Tower root:    6.023148#011[D3] nut_snmp_get(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:37 Tower root:    6.023153#011[D3] nut_snmp_walk(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:37 Tower root:    6.023157#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:46:43 Tower root:   12.029002#011[D2] Can't get sysOID value (using nut_snmp_get_str())
Oct 28 02:46:43 Tower root:   12.029018#011[D3] load_mib2nut: failed with new match_sysoid() method
Oct 28 02:46:43 Tower root:   12.029023#011[D3] load_mib2nut: trying the new match_sysoid() method: attempt #2
Oct 28 02:46:43 Tower root:   12.029027#011[D3] Entering nut_snmp_get_oid()
Oct 28 02:46:43 Tower root:   12.029031#011[D3] nut_snmp_get(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:43 Tower root:   12.029034#011[D3] nut_snmp_walk(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:43 Tower root:   12.029038#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:46:49 Tower root:   18.035416#011[D2] Can't get sysOID value (using nut_snmp_get_oid())
Oct 28 02:46:49 Tower root:   18.035431#011[D3] Entering nut_snmp_get_str()
Oct 28 02:46:49 Tower root:   18.035436#011[D3] nut_snmp_get(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:49 Tower root:   18.035440#011[D3] nut_snmp_walk(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:49 Tower root:   18.035445#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:46:55 Tower root:   24.041775#011[D2] Can't get sysOID value (using nut_snmp_get_str())
Oct 28 02:46:55 Tower root:   24.041790#011[D3] load_mib2nut: failed with new match_sysoid() method
Oct 28 02:46:55 Tower root:   24.041795#011[D3] load_mib2nut: trying the new match_sysoid() method: attempt #3
Oct 28 02:46:55 Tower root:   24.041799#011[D3] Entering nut_snmp_get_oid()
Oct 28 02:46:55 Tower root:   24.041803#011[D3] nut_snmp_get(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:55 Tower root:   24.041807#011[D3] nut_snmp_walk(.1.3.6.1.2.1.1.2.0)
Oct 28 02:46:55 Tower root:   24.041810#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:01 Tower root:   30.048193#011[D2] Can't get sysOID value (using nut_snmp_get_oid())
Oct 28 02:47:01 Tower root:   30.048209#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:01 Tower root:   30.048213#011[D3] nut_snmp_get(.1.3.6.1.2.1.1.2.0)
Oct 28 02:47:01 Tower root:   30.048217#011[D3] nut_snmp_walk(.1.3.6.1.2.1.1.2.0)
Oct 28 02:47:01 Tower root:   30.048221#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:07 Tower root:   36.054560#011[D2] Can't get sysOID value (using nut_snmp_get_str())
Oct 28 02:47:07 Tower root:   36.054576#011[D3] load_mib2nut: failed with new match_sysoid() method
Oct 28 02:47:07 Tower root:   36.054581#011[D4] load_mib2nut: checking against mapping table entry #0 "apc_ats"
Oct 28 02:47:07 Tower root:   36.054585#011[D2] load_mib2nut: trying classic sysOID matching method with 'apc_ats' mib
Oct 28 02:47:07 Tower root:   36.054592#011[D3] su_find_info: "device.model" found
Oct 28 02:47:07 Tower root:   36.054596#011[D2] Found entry, not a template .1.3.6.1.4.1.318.1.1.8.1.5.0
Oct 28 02:47:07 Tower root:   36.054599#011[D2] Testing device.model using OID .1.3.6.1.4.1.318.1.1.8.1.5.0
Oct 28 02:47:07 Tower root:   36.054603#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:07 Tower root:   36.054606#011[D3] nut_snmp_get(.1.3.6.1.4.1.318.1.1.8.1.5.0)
Oct 28 02:47:07 Tower root:   36.054610#011[D3] nut_snmp_walk(.1.3.6.1.4.1.318.1.1.8.1.5.0)
Oct 28 02:47:07 Tower root:   36.054613#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:13 Tower root:   42.060082#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'apc_ats'!
Oct 28 02:47:13 Tower root:   42.060098#011[D4] load_mib2nut: checking against mapping table entry #1 "apc_pdu"
Oct 28 02:47:13 Tower root:   42.060102#011[D2] load_mib2nut: trying classic sysOID matching method with 'apc_pdu' mib
Oct 28 02:47:13 Tower root:   42.060109#011[D3] su_find_info: "device.model" found
Oct 28 02:47:13 Tower root:   42.060113#011[D2] Found entry, not a template .1.3.6.1.4.1.318.1.1.4.1.4.0
Oct 28 02:47:13 Tower root:   42.060116#011[D2] Testing device.model using OID .1.3.6.1.4.1.318.1.1.4.1.4.0
Oct 28 02:47:13 Tower root:   42.060120#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:13 Tower root:   42.060123#011[D3] nut_snmp_get(.1.3.6.1.4.1.318.1.1.4.1.4.0)
Oct 28 02:47:13 Tower root:   42.060127#011[D3] nut_snmp_walk(.1.3.6.1.4.1.318.1.1.4.1.4.0)
Oct 28 02:47:13 Tower root:   42.060131#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:16 Tower root: Startup timer elapsed, continuing...
Oct 28 02:47:16 Tower root: Network UPS Tools - UPS driver controller 2.8.0.1
Oct 28 02:47:19 Tower root:   48.065857#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'apc_pdu'!
Oct 28 02:47:19 Tower root:   48.065872#011[D4] load_mib2nut: checking against mapping table entry #2 "apc_pdu"
Oct 28 02:47:19 Tower root:   48.065877#011[D2] load_mib2nut: trying classic sysOID matching method with 'apc_pdu' mib
Oct 28 02:47:19 Tower root:   48.065882#011[D3] su_find_info: "device.model" found
Oct 28 02:47:19 Tower root:   48.065886#011[D2] Found entry, not a template .1.3.6.1.4.1.318.1.1.4.1.4.0
Oct 28 02:47:19 Tower root:   48.065890#011[D2] Testing device.model using OID .1.3.6.1.4.1.318.1.1.4.1.4.0
Oct 28 02:47:19 Tower root:   48.065893#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:19 Tower root:   48.065897#011[D3] nut_snmp_get(.1.3.6.1.4.1.318.1.1.4.1.4.0)
Oct 28 02:47:19 Tower root:   48.065900#011[D3] nut_snmp_walk(.1.3.6.1.4.1.318.1.1.4.1.4.0)
Oct 28 02:47:19 Tower root:   48.065904#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:25 Tower root:   54.071857#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'apc_pdu'!
Oct 28 02:47:25 Tower root:   54.071873#011[D4] load_mib2nut: checking against mapping table entry #3 "apc_pdu"
Oct 28 02:47:25 Tower root:   54.071878#011[D2] load_mib2nut: trying classic sysOID matching method with 'apc_pdu' mib
Oct 28 02:47:25 Tower root:   54.071884#011[D3] su_find_info: "device.model" found
Oct 28 02:47:25 Tower root:   54.071888#011[D2] Found entry, not a template .1.3.6.1.4.1.318.1.1.4.1.4.0
Oct 28 02:47:25 Tower root:   54.071892#011[D2] Testing device.model using OID .1.3.6.1.4.1.318.1.1.4.1.4.0
Oct 28 02:47:25 Tower root:   54.071895#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:25 Tower root:   54.071899#011[D3] nut_snmp_get(.1.3.6.1.4.1.318.1.1.4.1.4.0)
Oct 28 02:47:25 Tower root:   54.071903#011[D3] nut_snmp_walk(.1.3.6.1.4.1.318.1.1.4.1.4.0)
Oct 28 02:47:25 Tower root:   54.071906#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:31 Tower root:   60.077887#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'apc_pdu'!
Oct 28 02:47:31 Tower root:   60.077907#011[D4] load_mib2nut: checking against mapping table entry #4 "apc"
Oct 28 02:47:31 Tower root:   60.077912#011[D2] load_mib2nut: trying classic sysOID matching method with 'apc' mib
Oct 28 02:47:31 Tower root:   60.077917#011[D3] su_find_info: "device.model" found
Oct 28 02:47:31 Tower root:   60.077921#011[D2] Found entry, not a template .1.3.6.1.4.1.318.1.1.30.2.1.1.4.1
Oct 28 02:47:31 Tower root:   60.077924#011[D2] Testing device.model using OID .1.3.6.1.4.1.318.1.1.30.2.1.1.4.1
Oct 28 02:47:31 Tower root:   60.077928#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:31 Tower root:   60.077932#011[D3] nut_snmp_get(.1.3.6.1.4.1.318.1.1.30.2.1.1.4.1)
Oct 28 02:47:31 Tower root:   60.077935#011[D3] nut_snmp_walk(.1.3.6.1.4.1.318.1.1.30.2.1.1.4.1)
Oct 28 02:47:31 Tower root:   60.077938#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:37 Tower root:   66.083860#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'apc'!
Oct 28 02:47:37 Tower root:   66.083877#011[D4] load_mib2nut: checking against mapping table entry #5 "apcc"
Oct 28 02:47:37 Tower root:   66.083882#011[D2] load_mib2nut: trying classic sysOID matching method with 'apcc' mib
Oct 28 02:47:37 Tower root:   66.083895#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:47:37 Tower root:   66.083899#011[D3] su_find_info: "ups.model" found
Oct 28 02:47:37 Tower root:   66.083903#011[D2] Found entry, not a template .1.3.6.1.4.1.318.1.1.1.1.1.1.0
Oct 28 02:47:37 Tower root:   66.083907#011[D2] Testing ups.model using OID .1.3.6.1.4.1.318.1.1.1.1.1.1.0
Oct 28 02:47:37 Tower root:   66.083910#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:37 Tower root:   66.083914#011[D3] nut_snmp_get(.1.3.6.1.4.1.318.1.1.1.1.1.1.0)
Oct 28 02:47:37 Tower root:   66.083917#011[D3] nut_snmp_walk(.1.3.6.1.4.1.318.1.1.1.1.1.1.0)
Oct 28 02:47:37 Tower root:   66.083921#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:43 Tower root:   72.090108#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'apcc'!
Oct 28 02:47:43 Tower root:   72.090125#011[D4] load_mib2nut: checking against mapping table entry #6 "baytech"
Oct 28 02:47:43 Tower root:   72.090130#011[D2] load_mib2nut: trying classic sysOID matching method with 'baytech' mib
Oct 28 02:47:43 Tower root:   72.090136#011[D3] su_find_info: "device.model" found
Oct 28 02:47:43 Tower root:   72.090141#011[D2] Found entry, not a template .1.3.6.1.4.1.4779.1.3.5.2.1.24.1
Oct 28 02:47:43 Tower root:   72.090144#011[D2] Testing device.model using OID .1.3.6.1.4.1.4779.1.3.5.2.1.24.1
Oct 28 02:47:43 Tower root:   72.090148#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:43 Tower root:   72.090152#011[D3] nut_snmp_get(.1.3.6.1.4.1.4779.1.3.5.2.1.24.1)
Oct 28 02:47:43 Tower root:   72.090155#011[D3] nut_snmp_walk(.1.3.6.1.4.1.4779.1.3.5.2.1.24.1)
Oct 28 02:47:43 Tower root:   72.090159#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:49 Tower root:   78.096490#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'baytech'!
Oct 28 02:47:49 Tower root:   78.096505#011[D4] load_mib2nut: checking against mapping table entry #7 "bestpower"
Oct 28 02:47:49 Tower root:   78.096510#011[D2] load_mib2nut: trying classic sysOID matching method with 'bestpower' mib
Oct 28 02:47:49 Tower root:   78.096518#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:47:49 Tower root:   78.096523#011[D3] su_find_info: "ups.model" found
Oct 28 02:47:49 Tower root:   78.096526#011[D2] Found entry, not a template .1.3.6.1.4.1.2947.1.1.2.0
Oct 28 02:47:49 Tower root:   78.096530#011[D2] Testing ups.model using OID .1.3.6.1.4.1.2947.1.1.2.0
Oct 28 02:47:49 Tower root:   78.096533#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:49 Tower root:   78.096537#011[D3] nut_snmp_get(.1.3.6.1.4.1.2947.1.1.2.0)
Oct 28 02:47:49 Tower root:   78.096541#011[D3] nut_snmp_walk(.1.3.6.1.4.1.2947.1.1.2.0)
Oct 28 02:47:49 Tower root:   78.096545#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:47:55 Tower root:   84.102869#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'bestpower'!
Oct 28 02:47:55 Tower root:   84.102885#011[D4] load_mib2nut: checking against mapping table entry #8 "cpqpower"
Oct 28 02:47:55 Tower root:   84.102890#011[D2] load_mib2nut: trying classic sysOID matching method with 'cpqpower' mib
Oct 28 02:47:55 Tower root:   84.102903#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:47:55 Tower root:   84.102907#011[D3] su_find_info: "ups.model" found
Oct 28 02:47:55 Tower root:   84.102911#011[D2] Found entry, not a template .1.3.6.1.4.1.232.165.3.1.2.0
Oct 28 02:47:55 Tower root:   84.102915#011[D2] Testing ups.model using OID .1.3.6.1.4.1.232.165.3.1.2.0
Oct 28 02:47:55 Tower root:   84.102919#011[D3] Entering nut_snmp_get_str()
Oct 28 02:47:55 Tower root:   84.102922#011[D3] nut_snmp_get(.1.3.6.1.4.1.232.165.3.1.2.0)
Oct 28 02:47:55 Tower root:   84.102926#011[D3] nut_snmp_walk(.1.3.6.1.4.1.232.165.3.1.2.0)
Oct 28 02:47:55 Tower root:   84.102929#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:01 Tower root:   90.108920#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'cpqpower'!
Oct 28 02:48:01 Tower root:   90.108936#011[D4] load_mib2nut: checking against mapping table entry #9 "cyberpower"
Oct 28 02:48:01 Tower root:   90.108941#011[D2] load_mib2nut: trying classic sysOID matching method with 'cyberpower' mib
Oct 28 02:48:01 Tower root:   90.108951#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:48:01 Tower root:   90.108956#011[D3] su_find_info: "ups.model" found
Oct 28 02:48:01 Tower root:   90.108960#011[D2] Found entry, not a template .1.3.6.1.4.1.3808.1.1.1.1.1.1.0
Oct 28 02:48:01 Tower root:   90.108963#011[D2] Testing ups.model using OID .1.3.6.1.4.1.3808.1.1.1.1.1.1.0
Oct 28 02:48:01 Tower root:   90.108966#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:01 Tower root:   90.108970#011[D3] nut_snmp_get(.1.3.6.1.4.1.3808.1.1.1.1.1.1.0)
Oct 28 02:48:01 Tower root:   90.108974#011[D3] nut_snmp_walk(.1.3.6.1.4.1.3808.1.1.1.1.1.1.0)
Oct 28 02:48:01 Tower root:   90.108977#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:07 Tower root:   96.115335#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'cyberpower'!
Oct 28 02:48:07 Tower root:   96.115350#011[D4] load_mib2nut: checking against mapping table entry #10 "cyberpower"
Oct 28 02:48:07 Tower root:   96.115355#011[D2] load_mib2nut: trying classic sysOID matching method with 'cyberpower' mib
Oct 28 02:48:07 Tower root:   96.115366#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:48:07 Tower root:   96.115371#011[D3] su_find_info: "ups.model" found
Oct 28 02:48:07 Tower root:   96.115374#011[D2] Found entry, not a template .1.3.6.1.4.1.3808.1.1.1.1.1.1.0
Oct 28 02:48:07 Tower root:   96.115378#011[D2] Testing ups.model using OID .1.3.6.1.4.1.3808.1.1.1.1.1.1.0
Oct 28 02:48:07 Tower root:   96.115381#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:07 Tower root:   96.115385#011[D3] nut_snmp_get(.1.3.6.1.4.1.3808.1.1.1.1.1.1.0)
Oct 28 02:48:07 Tower root:   96.115389#011[D3] nut_snmp_walk(.1.3.6.1.4.1.3808.1.1.1.1.1.1.0)
Oct 28 02:48:07 Tower root:   96.115398#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:13 Tower root:  102.121049#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'cyberpower'!
Oct 28 02:48:13 Tower root:  102.121067#011[D4] load_mib2nut: checking against mapping table entry #11 "delta_ups"
Oct 28 02:48:13 Tower root:  102.121072#011[D2] load_mib2nut: trying classic sysOID matching method with 'delta_ups' mib
Oct 28 02:48:13 Tower root:  102.121081#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:48:13 Tower root:  102.121086#011[D3] su_find_info: "ups.model" found
Oct 28 02:48:13 Tower root:  102.121089#011[D2] Found entry, not a template .1.3.6.1.4.1.2254.2.4.1.2.0
Oct 28 02:48:13 Tower root:  102.121093#011[D2] Testing ups.model using OID .1.3.6.1.4.1.2254.2.4.1.2.0
Oct 28 02:48:13 Tower root:  102.121097#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:13 Tower root:  102.121101#011[D3] nut_snmp_get(.1.3.6.1.4.1.2254.2.4.1.2.0)
Oct 28 02:48:13 Tower root:  102.121104#011[D3] nut_snmp_walk(.1.3.6.1.4.1.2254.2.4.1.2.0)
Oct 28 02:48:13 Tower root:  102.121108#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:19 Tower root:  108.127400#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'delta_ups'!
Oct 28 02:48:19 Tower root:  108.127417#011[D4] load_mib2nut: checking against mapping table entry #12 "eaton_ats16_nmc"
Oct 28 02:48:19 Tower root:  108.127422#011[D2] load_mib2nut: trying classic sysOID matching method with 'eaton_ats16_nmc' mib
Oct 28 02:48:19 Tower root:  108.127429#011[D3] su_find_info: "device.model" found
Oct 28 02:48:19 Tower root:  108.127433#011[D2] Found entry, not a template .1.3.6.1.4.1.534.10.2.1.2.0
Oct 28 02:48:19 Tower root:  108.127437#011[D2] Testing device.model using OID .1.3.6.1.4.1.534.10.2.1.2.0
Oct 28 02:48:19 Tower root:  108.127440#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:19 Tower root:  108.127444#011[D3] nut_snmp_get(.1.3.6.1.4.1.534.10.2.1.2.0)
Oct 28 02:48:19 Tower root:  108.127448#011[D3] nut_snmp_walk(.1.3.6.1.4.1.534.10.2.1.2.0)
Oct 28 02:48:19 Tower root:  108.127452#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:25 Tower root:  114.133743#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'eaton_ats16_nmc'!
Oct 28 02:48:25 Tower root:  114.133759#011[D4] load_mib2nut: checking against mapping table entry #13 "eaton_ats16_nm2"
Oct 28 02:48:25 Tower root:  114.133764#011[D2] load_mib2nut: trying classic sysOID matching method with 'eaton_ats16_nm2' mib
Oct 28 02:48:25 Tower root:  114.133770#011[D3] su_find_info: "device.model" found
Oct 28 02:48:25 Tower root:  114.133775#011[D2] Found entry, not a template .1.3.6.1.4.1.534.10.2.1.2.0
Oct 28 02:48:25 Tower root:  114.133778#011[D2] Testing device.model using OID .1.3.6.1.4.1.534.10.2.1.2.0
Oct 28 02:48:25 Tower root:  114.133782#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:25 Tower root:  114.133786#011[D3] nut_snmp_get(.1.3.6.1.4.1.534.10.2.1.2.0)
Oct 28 02:48:25 Tower root:  114.133789#011[D3] nut_snmp_walk(.1.3.6.1.4.1.534.10.2.1.2.0)
Oct 28 02:48:25 Tower root:  114.133793#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:31 Tower root:  120.140109#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'eaton_ats16_nm2'!
Oct 28 02:48:31 Tower root:  120.140137#011[D4] load_mib2nut: checking against mapping table entry #14 "eaton_ats30"
Oct 28 02:48:31 Tower root:  120.140143#011[D2] load_mib2nut: trying classic sysOID matching method with 'eaton_ats30' mib
Oct 28 02:48:31 Tower root:  120.140149#011[D3] su_find_info: "device.model" found
Oct 28 02:48:31 Tower root:  120.140155#011[D2] Found entry, not a template .1.3.6.1.4.1.534.10.1.2.1.0
Oct 28 02:48:31 Tower root:  120.140159#011[D2] Testing device.model using OID .1.3.6.1.4.1.534.10.1.2.1.0
Oct 28 02:48:31 Tower root:  120.140163#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:31 Tower root:  120.140166#011[D3] nut_snmp_get(.1.3.6.1.4.1.534.10.1.2.1.0)
Oct 28 02:48:31 Tower root:  120.140170#011[D3] nut_snmp_walk(.1.3.6.1.4.1.534.10.1.2.1.0)
Oct 28 02:48:31 Tower root:  120.140174#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:37 Tower root:  126.145929#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'eaton_ats30'!
Oct 28 02:48:37 Tower root:  126.145945#011[D4] load_mib2nut: checking against mapping table entry #15 "eaton_epdu"
Oct 28 02:48:37 Tower root:  126.145950#011[D2] load_mib2nut: trying classic sysOID matching method with 'eaton_epdu' mib
Oct 28 02:48:37 Tower root:  126.145956#011[D3] su_find_info: "device.model" found
Oct 28 02:48:37 Tower root:  126.145961#011[D2] Found template, need to be adapted
Oct 28 02:48:37 Tower root:  126.145965#011[D2] Testing device.model using OID .1.3.6.1.4.1.534.6.6.7.1.2.1.2.0
Oct 28 02:48:37 Tower root:  126.145969#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:37 Tower root:  126.145973#011[D3] nut_snmp_get(.1.3.6.1.4.1.534.6.6.7.1.2.1.2.0)
Oct 28 02:48:37 Tower root:  126.145977#011[D3] nut_snmp_walk(.1.3.6.1.4.1.534.6.6.7.1.2.1.2.0)
Oct 28 02:48:37 Tower root:  126.145996#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:43 Tower root:  132.152309#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'eaton_epdu'!
Oct 28 02:48:43 Tower root:  132.152325#011[D4] load_mib2nut: checking against mapping table entry #16 "eaton_pdu_nlogic"
Oct 28 02:48:43 Tower root:  132.152330#011[D2] load_mib2nut: trying classic sysOID matching method with 'eaton_pdu_nlogic' mib
Oct 28 02:48:43 Tower root:  132.152336#011[D3] su_find_info: "device.model" found
Oct 28 02:48:43 Tower root:  132.152341#011[D2] Found entry, not a template .1.3.6.1.4.1.534.7.1.1.2.1.3.1
Oct 28 02:48:43 Tower root:  132.152345#011[D2] Testing device.model using OID .1.3.6.1.4.1.534.7.1.1.2.1.3.1
Oct 28 02:48:43 Tower root:  132.152348#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:43 Tower root:  132.152352#011[D3] nut_snmp_get(.1.3.6.1.4.1.534.7.1.1.2.1.3.1)
Oct 28 02:48:43 Tower root:  132.152356#011[D3] nut_snmp_walk(.1.3.6.1.4.1.534.7.1.1.2.1.3.1)
Oct 28 02:48:43 Tower root:  132.152360#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:49 Tower root:  138.158700#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'eaton_pdu_nlogic'!
Oct 28 02:48:49 Tower root:  138.158717#011[D4] load_mib2nut: checking against mapping table entry #17 "eaton_pxg_ups"
Oct 28 02:48:49 Tower root:  138.158722#011[D2] load_mib2nut: trying classic sysOID matching method with 'eaton_pxg_ups' mib
Oct 28 02:48:49 Tower root:  138.158739#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:48:49 Tower root:  138.158744#011[D3] su_find_info: "ups.model" found
Oct 28 02:48:49 Tower root:  138.158748#011[D2] Found entry, not a template 1.3.6.1.4.1.534.1.1.2.0
Oct 28 02:48:49 Tower root:  138.158752#011[D2] Testing ups.model using OID 1.3.6.1.4.1.534.1.1.2.0
Oct 28 02:48:49 Tower root:  138.158756#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:49 Tower root:  138.158759#011[D3] nut_snmp_get(1.3.6.1.4.1.534.1.1.2.0)
Oct 28 02:48:49 Tower root:  138.158763#011[D3] nut_snmp_walk(1.3.6.1.4.1.534.1.1.2.0)
Oct 28 02:48:49 Tower root:  138.158767#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:48:55 Tower root:  144.165103#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'eaton_pxg_ups'!
Oct 28 02:48:55 Tower root:  144.165120#011[D4] load_mib2nut: checking against mapping table entry #18 "eaton_pw_nm2"
Oct 28 02:48:55 Tower root:  144.165125#011[D2] load_mib2nut: trying classic sysOID matching method with 'eaton_pw_nm2' mib
Oct 28 02:48:55 Tower root:  144.165142#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:48:55 Tower root:  144.165147#011[D3] su_find_info: "ups.model" found
Oct 28 02:48:55 Tower root:  144.165151#011[D2] Found entry, not a template 1.3.6.1.4.1.534.1.1.2.0
Oct 28 02:48:55 Tower root:  144.165155#011[D2] Testing ups.model using OID 1.3.6.1.4.1.534.1.1.2.0
Oct 28 02:48:55 Tower root:  144.165158#011[D3] Entering nut_snmp_get_str()
Oct 28 02:48:55 Tower root:  144.165162#011[D3] nut_snmp_get(1.3.6.1.4.1.534.1.1.2.0)
Oct 28 02:48:55 Tower root:  144.165166#011[D3] nut_snmp_walk(1.3.6.1.4.1.534.1.1.2.0)
Oct 28 02:48:55 Tower root:  144.165170#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:01 Tower root:  150.170117#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'eaton_pw_nm2'!
Oct 28 02:49:01 Tower root:  150.170137#011[D4] load_mib2nut: checking against mapping table entry #19 "emerson_avocent_pdu"
Oct 28 02:49:01 Tower root:  150.170142#011[D2] load_mib2nut: trying classic sysOID matching method with 'emerson_avocent_pdu' mib
Oct 28 02:49:01 Tower root:  150.170148#011[D3] su_find_info: "device.model" found
Oct 28 02:49:01 Tower root:  150.170152#011[D2] Found template, need to be adapted
Oct 28 02:49:01 Tower root:  150.170157#011[D2] Testing device.model using OID .1.3.6.1.4.1.10418.17.2.5.3.1.5.1.0
Oct 28 02:49:01 Tower root:  150.170161#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:01 Tower root:  150.170164#011[D3] nut_snmp_get(.1.3.6.1.4.1.10418.17.2.5.3.1.5.1.0)
Oct 28 02:49:01 Tower root:  150.170168#011[D3] nut_snmp_walk(.1.3.6.1.4.1.10418.17.2.5.3.1.5.1.0)
Oct 28 02:49:01 Tower root:  150.170171#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:07 Tower root:  156.176116#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'emerson_avocent_pdu'!
Oct 28 02:49:07 Tower root:  156.176133#011[D4] load_mib2nut: checking against mapping table entry #20 "aphel_revelation"
Oct 28 02:49:07 Tower root:  156.176137#011[D2] load_mib2nut: trying classic sysOID matching method with 'aphel_revelation' mib
Oct 28 02:49:07 Tower root:  156.176144#011[D3] su_find_info: "device.model" found
Oct 28 02:49:07 Tower root:  156.176148#011[D2] Found entry, not a template .1.3.6.1.4.1.534.6.6.6.1.1.12.0
Oct 28 02:49:07 Tower root:  156.176152#011[D2] Testing device.model using OID .1.3.6.1.4.1.534.6.6.6.1.1.12.0
Oct 28 02:49:07 Tower root:  156.176156#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:07 Tower root:  156.176160#011[D3] nut_snmp_get(.1.3.6.1.4.1.534.6.6.6.1.1.12.0)
Oct 28 02:49:07 Tower root:  156.176163#011[D3] nut_snmp_walk(.1.3.6.1.4.1.534.6.6.6.1.1.12.0)
Oct 28 02:49:07 Tower root:  156.176167#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:13 Tower root:  162.182518#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'aphel_revelation'!
Oct 28 02:49:13 Tower root:  162.182535#011[D4] load_mib2nut: checking against mapping table entry #21 "aphel_genesisII"
Oct 28 02:49:13 Tower root:  162.182540#011[D2] load_mib2nut: trying classic sysOID matching method with 'aphel_genesisII' mib
Oct 28 02:49:13 Tower root:  162.182546#011[D3] su_find_info: "device.model" found
Oct 28 02:49:13 Tower root:  162.182551#011[D2] Found entry, not a template .1.3.6.1.4.1.17373.3.1.1.0
Oct 28 02:49:13 Tower root:  162.182554#011[D2] Testing device.model using OID .1.3.6.1.4.1.17373.3.1.1.0
Oct 28 02:49:13 Tower root:  162.182558#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:13 Tower root:  162.182562#011[D3] nut_snmp_get(.1.3.6.1.4.1.17373.3.1.1.0)
Oct 28 02:49:13 Tower root:  162.182566#011[D3] nut_snmp_walk(.1.3.6.1.4.1.17373.3.1.1.0)
Oct 28 02:49:13 Tower root:  162.182569#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:19 Tower root:  168.188894#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'aphel_genesisII'!
Oct 28 02:49:19 Tower root:  168.188911#011[D4] load_mib2nut: checking against mapping table entry #22 "pulizzi_switched1"
Oct 28 02:49:19 Tower root:  168.188916#011[D2] load_mib2nut: trying classic sysOID matching method with 'pulizzi_switched1' mib
Oct 28 02:49:19 Tower root:  168.188922#011[D3] su_find_info: "device.model" found
Oct 28 02:49:19 Tower root:  168.188927#011[D2] Found entry, not a template .1.3.6.1.4.1.20677.2.1.1.0
Oct 28 02:49:19 Tower root:  168.188930#011[D2] Testing device.model using OID .1.3.6.1.4.1.20677.2.1.1.0
Oct 28 02:49:19 Tower root:  168.188934#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:19 Tower root:  168.188938#011[D3] nut_snmp_get(.1.3.6.1.4.1.20677.2.1.1.0)
Oct 28 02:49:19 Tower root:  168.188941#011[D3] nut_snmp_walk(.1.3.6.1.4.1.20677.2.1.1.0)
Oct 28 02:49:19 Tower root:  168.188945#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:25 Tower root:  174.195245#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'pulizzi_switched1'!
Oct 28 02:49:25 Tower root:  174.195262#011[D4] load_mib2nut: checking against mapping table entry #23 "pulizzi_switched2"
Oct 28 02:49:25 Tower root:  174.195267#011[D2] load_mib2nut: trying classic sysOID matching method with 'pulizzi_switched2' mib
Oct 28 02:49:25 Tower root:  174.195273#011[D3] su_find_info: "device.model" found
Oct 28 02:49:25 Tower root:  174.195278#011[D2] Found entry, not a template .1.3.6.1.4.1.20677.2.1.1.0
Oct 28 02:49:25 Tower root:  174.195281#011[D2] Testing device.model using OID .1.3.6.1.4.1.20677.2.1.1.0
Oct 28 02:49:25 Tower root:  174.195285#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:25 Tower root:  174.195289#011[D3] nut_snmp_get(.1.3.6.1.4.1.20677.2.1.1.0)
Oct 28 02:49:25 Tower root:  174.195292#011[D3] nut_snmp_walk(.1.3.6.1.4.1.20677.2.1.1.0)
Oct 28 02:49:25 Tower root:  174.195296#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:31 Tower root:  180.201609#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'pulizzi_switched2'!
Oct 28 02:49:31 Tower root:  180.201627#011[D4] load_mib2nut: checking against mapping table entry #24 "hpe_epdu"
Oct 28 02:49:31 Tower root:  180.201631#011[D2] load_mib2nut: trying classic sysOID matching method with 'hpe_epdu' mib
Oct 28 02:49:31 Tower root:  180.201639#011[D3] su_find_info: "device.model" found
Oct 28 02:49:31 Tower root:  180.201643#011[D2] Found template, need to be adapted
Oct 28 02:49:31 Tower root:  180.201648#011[D2] Testing device.model using OID .1.3.6.1.4.1.232.165.7.1.2.1.3.0
Oct 28 02:49:31 Tower root:  180.201652#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:31 Tower root:  180.201656#011[D3] nut_snmp_get(.1.3.6.1.4.1.232.165.7.1.2.1.3.0)
Oct 28 02:49:31 Tower root:  180.201659#011[D3] nut_snmp_walk(.1.3.6.1.4.1.232.165.7.1.2.1.3.0)
Oct 28 02:49:31 Tower root:  180.201663#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:37 Tower root:  186.208007#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'hpe_epdu'!
Oct 28 02:49:37 Tower root:  186.208025#011[D4] load_mib2nut: checking against mapping table entry #25 "hpe_pdu3_cis"
Oct 28 02:49:37 Tower root:  186.208029#011[D2] load_mib2nut: trying classic sysOID matching method with 'hpe_pdu3_cis' mib
Oct 28 02:49:37 Tower root:  186.208036#011[D3] su_find_info: "device.model" found
Oct 28 02:49:37 Tower root:  186.208040#011[D2] Found entry, not a template .1.3.6.1.4.1.232.165.11.1.2.1.3.1
Oct 28 02:49:37 Tower root:  186.208044#011[D2] Testing device.model using OID .1.3.6.1.4.1.232.165.11.1.2.1.3.1
Oct 28 02:49:37 Tower root:  186.208047#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:37 Tower root:  186.208051#011[D3] nut_snmp_get(.1.3.6.1.4.1.232.165.11.1.2.1.3.1)
Oct 28 02:49:37 Tower root:  186.208055#011[D3] nut_snmp_walk(.1.3.6.1.4.1.232.165.11.1.2.1.3.1)
Oct 28 02:49:37 Tower root:  186.208059#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:43 Tower root:  192.213859#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'hpe_pdu3_cis'!
Oct 28 02:49:43 Tower root:  192.213877#011[D4] load_mib2nut: checking against mapping table entry #26 "huawei"
Oct 28 02:49:43 Tower root:  192.213882#011[D2] load_mib2nut: trying classic sysOID matching method with 'huawei' mib
Oct 28 02:49:43 Tower root:  192.213893#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:49:43 Tower root:  192.213897#011[D3] su_find_info: "ups.model" found
Oct 28 02:49:43 Tower root:  192.213901#011[D2] Found entry, not a template .1.3.6.1.4.1.2011.6.174.1.2.100.1.2.1
Oct 28 02:49:43 Tower root:  192.213905#011[D2] Testing ups.model using OID .1.3.6.1.4.1.2011.6.174.1.2.100.1.2.1
Oct 28 02:49:43 Tower root:  192.213909#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:43 Tower root:  192.213913#011[D3] nut_snmp_get(.1.3.6.1.4.1.2011.6.174.1.2.100.1.2.1)
Oct 28 02:49:43 Tower root:  192.213917#011[D3] nut_snmp_walk(.1.3.6.1.4.1.2011.6.174.1.2.100.1.2.1)
Oct 28 02:49:43 Tower root:  192.213920#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:49 Tower root:  198.220028#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'huawei'!
Oct 28 02:49:49 Tower root:  198.220054#011[D4] load_mib2nut: checking against mapping table entry #27 "mge"
Oct 28 02:49:49 Tower root:  198.220060#011[D2] load_mib2nut: trying classic sysOID matching method with 'mge' mib
Oct 28 02:49:49 Tower root:  198.220073#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:49:49 Tower root:  198.220078#011[D3] su_find_info: "ups.model" found
Oct 28 02:49:49 Tower root:  198.220082#011[D2] Found entry, not a template .1.3.6.1.4.1.705.1.1.1.0
Oct 28 02:49:49 Tower root:  198.220091#011[D2] Testing ups.model using OID .1.3.6.1.4.1.705.1.1.1.0
Oct 28 02:49:49 Tower root:  198.220094#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:49 Tower root:  198.220098#011[D3] nut_snmp_get(.1.3.6.1.4.1.705.1.1.1.0)
Oct 28 02:49:49 Tower root:  198.220101#011[D3] nut_snmp_walk(.1.3.6.1.4.1.705.1.1.1.0)
Oct 28 02:49:49 Tower root:  198.220105#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:49:55 Tower root:  204.226452#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'mge'!
Oct 28 02:49:55 Tower root:  204.226468#011[D4] load_mib2nut: checking against mapping table entry #28 "netvision"
Oct 28 02:49:55 Tower root:  204.226473#011[D2] load_mib2nut: trying classic sysOID matching method with 'netvision' mib
Oct 28 02:49:55 Tower root:  204.226483#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:49:55 Tower root:  204.226488#011[D3] su_find_info: "ups.model" found
Oct 28 02:49:55 Tower root:  204.226492#011[D2] Found entry, not a template .1.3.6.1.4.1.4555.1.1.1.1.1.1.0
Oct 28 02:49:55 Tower root:  204.226495#011[D2] Testing ups.model using OID .1.3.6.1.4.1.4555.1.1.1.1.1.1.0
Oct 28 02:49:55 Tower root:  204.226499#011[D3] Entering nut_snmp_get_str()
Oct 28 02:49:55 Tower root:  204.226503#011[D3] nut_snmp_get(.1.3.6.1.4.1.4555.1.1.1.1.1.1.0)
Oct 28 02:49:55 Tower root:  204.226507#011[D3] nut_snmp_walk(.1.3.6.1.4.1.4555.1.1.1.1.1.1.0)
Oct 28 02:49:55 Tower root:  204.226511#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:50:01 Tower root:  210.231972#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'netvision'!
Oct 28 02:50:01 Tower root:  210.231992#011[D4] load_mib2nut: checking against mapping table entry #29 "raritan"
Oct 28 02:50:01 Tower root:  210.231997#011[D2] load_mib2nut: trying classic sysOID matching method with 'raritan' mib
Oct 28 02:50:01 Tower root:  210.232004#011[D3] su_find_info: "device.model" found
Oct 28 02:50:01 Tower root:  210.232008#011[D2] Found entry, not a template .1.3.6.1.4.1.13742.1.1.12.0
Oct 28 02:50:01 Tower root:  210.232012#011[D2] Testing device.model using OID .1.3.6.1.4.1.13742.1.1.12.0
Oct 28 02:50:01 Tower root:  210.232015#011[D3] Entering nut_snmp_get_str()
Oct 28 02:50:01 Tower root:  210.232019#011[D3] nut_snmp_get(.1.3.6.1.4.1.13742.1.1.12.0)
Oct 28 02:50:01 Tower root:  210.232022#011[D3] nut_snmp_walk(.1.3.6.1.4.1.13742.1.1.12.0)
Oct 28 02:50:01 Tower root:  210.232026#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:50:07 Tower root:  216.238354#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'raritan'!
Oct 28 02:50:07 Tower root:  216.238373#011[D4] load_mib2nut: checking against mapping table entry #30 "raritan-px2"
Oct 28 02:50:07 Tower root:  216.238378#011[D2] load_mib2nut: trying classic sysOID matching method with 'raritan-px2' mib
Oct 28 02:50:07 Tower root:  216.238387#011[D3] su_find_info: "device.model" found
Oct 28 02:50:07 Tower root:  216.238391#011[D2] Found entry, not a template .1.3.6.1.4.1.13742.6.3.2.1.1.3.1
Oct 28 02:50:07 Tower root:  216.238395#011[D2] Testing device.model using OID .1.3.6.1.4.1.13742.6.3.2.1.1.3.1
Oct 28 02:50:07 Tower root:  216.238399#011[D3] Entering nut_snmp_get_str()
Oct 28 02:50:07 Tower root:  216.238402#011[D3] nut_snmp_get(.1.3.6.1.4.1.13742.6.3.2.1.1.3.1)
Oct 28 02:50:07 Tower root:  216.238406#011[D3] nut_snmp_walk(.1.3.6.1.4.1.13742.6.3.2.1.1.3.1)
Oct 28 02:50:07 Tower root:  216.238415#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:50:13 Tower root:  222.243856#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'raritan-px2'!
Oct 28 02:50:13 Tower root:  222.243873#011[D4] load_mib2nut: checking against mapping table entry #31 "xppc"
Oct 28 02:50:13 Tower root:  222.243880#011[D2] load_mib2nut: trying classic sysOID matching method with 'xppc' mib
Oct 28 02:50:13 Tower root:  222.243887#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:50:13 Tower root:  222.243892#011[D3] su_find_info: "ups.model" found
Oct 28 02:50:13 Tower root:  222.243896#011[D2] Found entry, not a template .1.3.6.1.4.1.935.1.1.1.1.1.1.0
Oct 28 02:50:13 Tower root:  222.243900#011[D2] Testing ups.model using OID .1.3.6.1.4.1.935.1.1.1.1.1.1.0
Oct 28 02:50:13 Tower root:  222.243904#011[D3] Entering nut_snmp_get_str()
Oct 28 02:50:13 Tower root:  222.243908#011[D3] nut_snmp_get(.1.3.6.1.4.1.935.1.1.1.1.1.1.0)
Oct 28 02:50:13 Tower root:  222.243911#011[D3] nut_snmp_walk(.1.3.6.1.4.1.935.1.1.1.1.1.1.0)
Oct 28 02:50:13 Tower root:  222.243915#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:50:19 Tower root:  228.250237#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'xppc'!
Oct 28 02:50:19 Tower root:  228.250254#011[D4] load_mib2nut: checking against mapping table entry #32 "tripplite"
Oct 28 02:50:19 Tower root:  228.250259#011[D2] load_mib2nut: trying classic sysOID matching method with 'tripplite' mib
Oct 28 02:50:19 Tower root:  228.250272#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:50:19 Tower root:  228.250277#011[D3] su_find_info: "ups.model" found
Oct 28 02:50:19 Tower root:  228.250281#011[D2] Found entry, not a template 1.3.6.1.2.1.33.1.1.2.0
Oct 28 02:50:19 Tower root:  228.250285#011[D2] Testing ups.model using OID 1.3.6.1.2.1.33.1.1.2.0
Oct 28 02:50:19 Tower root:  228.250289#011[D3] Entering nut_snmp_get_str()
Oct 28 02:50:19 Tower root:  228.250292#011[D3] nut_snmp_get(1.3.6.1.2.1.33.1.1.2.0)
Oct 28 02:50:19 Tower root:  228.250296#011[D3] nut_snmp_walk(1.3.6.1.2.1.33.1.1.2.0)
Oct 28 02:50:19 Tower root:  228.250300#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:50:25 Tower root:  234.256638#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'tripplite'!
Oct 28 02:50:25 Tower root:  234.256655#011[D4] load_mib2nut: checking against mapping table entry #33 "ietf"
Oct 28 02:50:25 Tower root:  234.256660#011[D2] load_mib2nut: trying classic sysOID matching method with 'ietf' mib
Oct 28 02:50:25 Tower root:  234.256674#011[D3] su_find_info: unknown info type (device.model)
Oct 28 02:50:25 Tower root:  234.256678#011[D3] su_find_info: "ups.model" found
Oct 28 02:50:25 Tower root:  234.256682#011[D2] Found entry, not a template 1.3.6.1.2.1.33.1.1.2.0
Oct 28 02:50:25 Tower root:  234.256686#011[D2] Testing ups.model using OID 1.3.6.1.2.1.33.1.1.2.0
Oct 28 02:50:25 Tower root:  234.256690#011[D3] Entering nut_snmp_get_str()
Oct 28 02:50:25 Tower root:  234.256694#011[D3] nut_snmp_get(1.3.6.1.2.1.33.1.1.2.0)
Oct 28 02:50:25 Tower root:  234.256697#011[D3] nut_snmp_walk(1.3.6.1.2.1.33.1.1.2.0)
Oct 28 02:50:25 Tower root:  234.256701#011[D4] nut_snmp_walk: max. iteration = 1
Oct 28 02:50:31 Tower root:  240.262902#011[D3] load_mib2nut: testOID provided and doesn't match MIB 'ietf'!
Oct 28 02:50:31 Tower root:  240.262918#011No supported device detected at [ups] (host 192.168.0.238)
Oct 28 02:50:31 Tower root:  240.262987#011upsnotify: failed to notify about state 4: no notification tech defined, will not spam more about it
Oct 28 02:50:31 Tower root: Network UPS Tools - Generic SNMP UPS driver 1.30 (2.8.0.1)
desertwitch commented 11 months ago

Also relevant: https://github.com/networkupstools/nut/blob/858db30fef2e6854b114eeb1306381b59c05f848/drivers/snmp-ups.c#L618

jimklimov commented 11 months ago

As far as I know, with at least classic UDP-based SNMP, the lack of server or wrong password are indistinguishable: you fire a best effort UDP packet, no reply comes in, that's it. After an arbitrary timeout you decide to give up and do not know if the server is not available, or chose to not reply (bad auth, stressed, etc.), or either packet got lost in transit... There is no "session" whose state you can track to gauge success of the attempt, like with TCP. More or less the same can be seen with standard tools like snmpwalk.

Just to clarify: in the environments you work with, are init-scripts still the "king of the day" (so e.g. NUT drivers' long init times can be blocking the appearance of interactive console login), or are service frameworks like systemd or SMF available? In particular, what I'd expect of "frameworks" includes:

So how much are you limited by requiring upsdrvctl as a single program to start all drivers successfully and in one shot (or fail on any hiccup) as a unitary step in the system boot-up?

Regarding configurability for this, check https://github.com/networkupstools/nut/blob/master/conf/ups.conf.sample - in particular: maxretry, retrydelay and overall maxstartdelay.

In trench experience of the 42ity project for massive-monitoring appliances, the burst of driver inits could overwhelm the appliance CPU to the point that it timed out every driver across the 3-minute boot allowance. Ended up making a special systemd unit that wrapped nut-driver@instancename.service logic to keep those per-driver units off by default and to "manually" start them in batches of 30 or so.

desertwitch commented 11 months ago

Thanks for getting back to me in light speed (again), Jim.

As far as I know, with at least classic UDP-based SNMP, the lack of server or wrong password are indistinguishable: you fire a best effort UDP packet, no reply comes in, that's it. After an arbitrary timeout you decide to give up and do not know if the server is not available, or chose to not reply (bad auth, stressed, etc.), or either packet got lost in transit... There is no "session" whose state you can track to gauge success of the attempt, like with TCP. More or less the same can be seen with standard tools like snmpwalk.

This is also what I've gathered from my investigations into this - so it seems to be a cul-de-sac (protocol-wise).

Just to clarify: in the environments you work with, are init-scripts still the "king of the day" (so e.g. NUT drivers' long init times can be blocking the appearance of interactive console login), or are service frameworks like systemd or SMF available? In particular, what I'd expect of "frameworks" includes:

Init-scripts - but makes one get creative with such things... :-)

So how much are you limited by requiring upsdrvctl as a single program to start all drivers successfully and in one shot (or fail on any hiccup) as a unitary step in the system boot-up?

Not massively, but it's certainly a convenience not having to evaluate which drivers my end-users have configured. In any case I'd say most have max. 2 configured, if not just 1, so that's pretty much a non-issue (starting up too many at once).

Regarding configurability for this, check https://github.com/networkupstools/nut/blob/master/conf/ups.conf.sample - in particular: maxretry, retrydelay and overall maxstartdelay.

I had the feeling I missed something, sorry about that... But reading up on that does that make me wonder about that timeout.

# maxstartdelay: OPTIONAL.  This can be set as a global variable
#                above your first UPS definition and it can also be
#                set in a UPS section.  This value controls how long
#                upsdrvctl will wait for the driver to finish starting.
#                This keeps your system from getting stuck due to a
#                broken driver or UPS.
#                The default is 45 seconds.

Default (when not explicitly set) seems 45 seconds, resulting (probably) in this log line (45 secs after start):

Oct 28 02:47:16 Tower root: Startup timer elapsed, continuing...

Following that logic shouldn't the SNMP driver have been killed (here) after these 45 seconds elapsed?

jimklimov commented 11 months ago

Looking at code, seems it would retry (3 times by default in the ups.conf.sample, 1 in code) so forking off new drivers. In fact, there does not seem to be any reaping for drivers that just timed out but did not die during forkexec() - though usually they should avoid stepping on each other's toes by killing off an earlier instance themselves.

At least, if the timeouts you see are like 3*45 sec - that may be it.

desertwitch commented 11 months ago

Looking at code, seems it would retry (3 times by default in the ups.conf.sample, 1 in code) so forking off new drivers. In fact, there does not seem to be any reaping for drivers that just timed out but did not die during forkexec() - though usually they should avoid stepping on each other's toes by killing off an earlier instance themselves.

At least, if the timeouts you see are like 3*45 sec - that may be it.

I'll investigate some more into this, because I don't have maxretry set in my ups.conf.

So it should default into 1(default maxretry)*45(default maxstartdelay) = 45 seconds

Those 45 seconds being the first and only time that log line appears: Oct 28 02:47:16 Tower root: Startup timer elapsed, continuing...

But even with 3(maxretry)*45(maxstartdelay) = ~2,25 minutes (2,5 minutes with 3x the default retrydelay of 5s)

... something doesn't add up (if my logic is not flawed somehow here... which is always possible 😆 )

#    maxretry: OPTIONAL.  Specify the number of attempts to start the driver(s),
#              in case of failure, before giving up. A delay of 'retrydelay' is
#              inserted between each attempt. Caution should be taken when using
#              this option, since it can impact the time taken by your system to
#              start.
#
#              The built-in default is 1 attempt.

In my logs it seems the driver is only started once, and kills itself after the 4 minutes, rather than being killed by any upsdrvctl timeouts - so perhaps upsdrvctl is already considering the driver started at that point, but more likely it doesn't kill it as it should after this log line: Oct 28 02:47:16 Tower root: Startup timer elapsed, continuing.... That is under the assumption that "continuing..." in this case means continuing to the next defined UPS (none, in my case) rather than continuing with the already running driver despite the "timer elapsed".

desertwitch commented 11 months ago

Diving into the code all these cases (except for the first) already have a dead fork at that point (and no need to terminate it)

https://github.com/networkupstools/nut/blob/858db30fef2e6854b114eeb1306381b59c05f848/drivers/upsdrvctl.c#L668-L693

Upstream function evaluating the error counter doesn't terminate, just checks whether to spawn new forks based on the options and whether an error was encountered (which it was, just not resulting in fork termination by it's own fatality): https://github.com/networkupstools/nut/blob/858db30fef2e6854b114eeb1306381b59c05f848/drivers/upsdrvctl.c#L893-L903

So it seems the fork never gets killed (because in all other cases it's already dead), so perhaps needs explicit killing here? https://github.com/networkupstools/nut/blob/858db30fef2e6854b114eeb1306381b59c05f848/drivers/upsdrvctl.c#L668-L672

desertwitch commented 11 months ago

I've tested this some more and it seems my assumption is right that an elapsed maxstartdelay does report an error to the upstream fork-spawning function (resulting in spawning of additional forks when maxretry > 1) but not in termination of the current time-elapsed fork. With the default setting of maxretry=1 the maxstartdelay basically does elapse (and does log it), no more forks get spawned (as intended), but that driver instance (fork) is never effectively terminated and runs forever until self-termination (as seen in the logs).

Usually not a problem because I'd assume most other drivers would exit on their own accord way before time-elapsing (and not needing killing in the process), but with SNMP that seems to be the case (it needing killing, which it doesn't seem to get).

But maxstartdelay seems to have no (killing, just fork-spawning) effect at present implementation, not as (probably) intended at least.

P.S For the SNMP driver a SIGTERM didn't seem to suffice at that stage (patching one in for test purposes), it needed a SIGKILL to effectively kill the fork after the timeout elapsed.

jimklimov commented 11 months ago

My expectation was that the newly forked+execed driver would find (e.g. by PID file) that a predecessor exists, and would kill it then. On upsdrvctl side that previous attempt (if it did not fork off into the background again - something the debug flags can prevent by default) would probably become a zombie child process to be reaped explicitly (or eventually as upsdrvctl itself ends and the OS reaps its resources).

As for a SIGTERM - I think it is evaluated between loops in main.c, so if the driver is stuck in some time-consuming method for initialization, it might at best raise the "I'm terminated" flag with the signal handler, but never get to check/process it...

desertwitch commented 11 months ago

My expectation was that the newly forked+execed driver would find (e.g. by PID file) that a predecessor exists, and would kill it then. On upsdrvctl side that previous attempt (if it did not fork off into the background again - something the debug flags can prevent by default) would probably become a zombie child process to be reaped explicitly (or eventually as upsdrvctl itself ends and the OS reaps its resources).

As for a SIGTERM - I think it is evaluated between loops in main.c, so if the driver is stuck in some time-consuming method for initialization, it might at best raise the "I'm terminated" flag with the signal handler, but never get to check/process it...

That it does, but with a default maxretry=1 a second fork (killing the first one by detection) is never spawned (as intended), and the first fork just keeps running way past our maxstartdelay until (possible) self-termination (as it's never killed by a successive fork). The same applies with the last of multiple maxretry set as there's no successive fork killing it - the last one keeps running.

So methinks every such timeout error (possibly resulting or not resulting in further fork-spawning) should finish with a termination of the current (departing but possibly still running) fork and not rely on a successive fork to terminate it. Otherwise the option won't have its intended effect, when the last fork (of maxretry value X) is never terminated by the timeout, just the intermediate ones.

jimklimov commented 11 months ago

I think the idea is to try and start the driver after all :) So if it takes too long, upsdrvctl takes note and will probably return an error exit-code eventually, but marches on to start another driver (if there are many) while the attempted driver's forked process is on its own and no longer monitored to succeed or fail the start-up.

It would be counter-productive here to be pedantic and kill drivers just because they did not talk to some remote honeypot quickly enough.

BTW if wrapping into systemd/SMF units, keep in mind the framework settings for a process to start up (90 sec by default in systemd) and possibly tune that up for the slower remote devices. Especially the SNMP NMCs tended to time out or reboot under stress for us (when e.g. 30 clients bombard the same poor card with a full walk as they boot up).

desertwitch commented 11 months ago

I think the idea is to try and start the driver after all :) So if it takes too long, upsdrvctl takes note and will probably return an error exit-code eventually, but marches on to start another driver (if there are many) while the attempted driver's forked process is on its own and no longer monitored to succeed or fail the start-up.

It would be counter-productive here to be pedantic and kill drivers just because they did not talk to some remote honeypot quickly enough.

BTW if wrapping into systemd/SMF units, keep in mind the framework settings for a process to start up (90 sec by default in systemd) and possibly tune that up for the slower remote devices. Especially the SNMP NMCs tended to time out or reboot under stress for us (when e.g. 30 clients bombard the same poor card with a full walk as they boot up).

Makes sense when you say it like that. I'm good with keeping this as is with likely only one not immediately error-conscious driver affected. Wondering if it'd make sense to put a side-note as part of the maxstartdelay setting description that the timeout is more intended towards ensuring successive driver startup rather than cleaning up stale driver instances. But I'm good as far as this issue is concerned... thanks for the time as usual, Jim, and sorry if it caused any inconvenience.

jimklimov commented 11 months ago

A docs update may be worthwhile. After all, it is from outside that the missing bits are best visible :)

desertwitch commented 11 months ago

Thanks for the commit, one last thing I was wondering about when reading your side-note:

Note that after this time upsdrvctl would just move along with its business (whether retrying the same driver if maxretry>1, or trying another driver if starting them all, or just exit); however the most recently started "stuck" driver process may be further initializing in the background, and might even succeed eventually.

upsdrvctl doesn't actually exit until the SNMP driver self-terminates after the 4 minutes. It doesn't let the driver do its hopeless thing in the background either, as I understand from the above paragraph. That is with 1 driver configured and default settings of maxretry=1, maxstartdelay=45 seconds - this is still "normal", right?

Not trying to pick words or be overly pedantic, just sanity-checking we were talking about the same thing. :-)

jimklimov commented 11 months ago

Well, normally the drivers initialize, fork to background (unless told not to), and begin the infinite polling loop. So if the driver would succeed eventually - its thing should not be hopeless :)

Then it depends on the system around it. If e.g. upsdrvctl returns a non-zero (error) exit-code because it had some hiccups, some systemd might restart the unit anyway. If timings are wrong for the practical situation, I guess it might even "boot-loop" the nut-driver(s) unit this way...

jimklimov commented 11 months ago

Not sure what to state about upsdrvctl not exiting until child processes actually finish (fail or fork)... I suppose, that is correct (and notes can be further reworded about "eventual" exit). For a start of single driver might as well wait and pass its result code.

desertwitch commented 11 months ago

Not sure what to state about upsdrvctl not exiting until child processes actually finish (fail or fork)... I suppose, that is correct (and notes can be further reworded about "eventual" exit). For a start of single driver might as well wait and pass its result code.

All good then, many thanks for going down that rabbit hole with me. As far as I'm concerned, issue can be closed since there seems little room for improvement SNMP-wise.

... and again, thanks for keeping the NUT-wheel spinning for us! ;-)

jimklimov commented 11 months ago

Update about not blocking the system startup due to upsdrvctl - check the nowait flag too.

jimklimov commented 10 months ago

@desertwitch : do you think solvable issues here have been solved?

I guess that for SNMP over UDP the inability to discern un-handled requests from dead hosts is more or less fundamental, so we have to try all detection OIDs etc. and come to conclusions after receiving no replies.

Looking at nut_snmp_init() we do not currently customize ports (non-161) nor protocol types (TCP); perhaps lack-of-host could be more visible with TCP - if the device talks that, and more so if it does not :) But I guess someone with actual devices to tap would have to implement this, as well as config file syntax changes.

desertwitch commented 10 months ago

Yep, I'm good here - thanks - feel free to close!

jimklimov commented 10 months ago

CC @arnaudquette-eaton @dzomaya : got any interest in enhancing SNMP low-level support per comments above?

I guess I'll offload the specific idea into the issue tracker as a separate thing.