is a script to monitor watchguard's cluster status,
the script can be downloaded here:

----------------------- > does not run on ubuntu 22.04 minimal installation

#analysing the script:

#working example
snmpget -t 10 -v 1 -c public .
SNMPv2-SMI::enterprises.3097. = INTEGER: 3

#not working example
snmpget -t 10 -v 1 -c pnpub .
iso. = INTEGER: 3

>> the problem is that the parsing of the result was failing, since there where only numeric oid's

>> so let's turn on SNMP mibs, in file /etc/snmp/snmp.conf:
# As the snmp packages come without MIB files due to license reasons, loading
# of MIBs is disabled by default. If you added the MIBs you can reenable
# loading them by commenting out the following line.
#mibs :
mibs SNMPv2-SMI

>> the line mibs SNMPv2-SMI was added after that the snmpget commands receives "SNMPv2-SMI::enterprises.3097. = INTEGER: 3" as result and the parsing was ok again

snmp packages installed on ubunut 22.04 LTS minimal installation:
ii libsnmp-base 5.9.1+dfsg-1ubuntu2.6 all SNMP configuration script, MIBs and documentation
ii libsnmp40:amd64 5.9.1+dfsg-1ubuntu2.6 amd64 SNMP (Simple Network Management Protocol) library
ii snmp 5.9.1+dfsg-1ubuntu2.6 amd64 SNMP (Simple Network Management Protocol) applications
ii snmp-mibs-downloader 1.5 all install and manage Management Information Base (MIB) files

computer2know :: thank you for your visit :: have a nice day :: © 2024