Check_mk Check-Plugins not working

(Tobias Grossmann) #1

Hi,

i want to use cisco_qos for a cisco Router, how do I configure that on Wato?
I can find just a list with all Plugins on https://mathias-kettner.com/cms_check_plugins_list.html, but not, how to use or activate them for a host.

regards,
Tobi

(Philipp Näther) #2

There is no manual interaction needed for this plugin on cmk side. If the router provides the interface description and qos class over snmp, it automatically creates a service for each combination. If it doesn’t, your router does not provide such information.

(Tobias Grossmann) #3

Hi,

sorry, I made two topics about the same problem. When I make a snmpwalk like the following, the router puts the ois out:

(Philipp Näther) #4

check if this OID gets you some useful info:

1.3.6.1.4.1.9.9.166.1.7.1.1.1

Do you have automatic service discovery enabled for your router? Because I am wondering why these services simply disappear.

(Tobias Grossmann) #5

Hi, here is the result:

root@Monitoring:~# snmpwalk -v2c -c Community IP-Address 1.3.6.1.4.1.9.9.166.1.7.1.1.1
iso.3.6.1.4.1.9.9.166.1.7.1.1.1.1593 = STRING: "class-default"
iso.3.6.1.4.1.9.9.166.1.7.1.1.1.324864002 = STRING: "SILVER"
iso.3.6.1.4.1.9.9.166.1.7.1.1.1.328180335 = STRING: "GOLD"
iso.3.6.1.4.1.9.9.166.1.7.1.1.1.330149229 = STRING: "ROUTING"
iso.3.6.1.4.1.9.9.166.1.7.1.1.1.331335087 = STRING: "VOIP"
(Tobias Grossmann) #6

Could it be that my MIBs are old?

root@Monitoring:/usr/share/snmp/mibs# ls -l
insgesamt 244
-rw-r--r-- 1 root root  1913 Okt  9  2018 GNOME-SMI.txt
-rw-r--r-- 1 root root  5931 Feb 19  2014 LM-SENSORS-MIB.txt
-rw-r--r-- 1 root root 15901 Feb 19  2014 NET-SNMP-AGENT-MIB.txt
-rw-r--r-- 1 root root  9160 Feb 19  2014 NET-SNMP-EXAMPLES-MIB.txt
-rw-r--r-- 1 root root  9326 Feb 19  2014 NET-SNMP-EXTEND-MIB.txt
-rw-r--r-- 1 root root  2036 Feb 19  2014 NET-SNMP-MIB.txt
-rw-r--r-- 1 root root  1215 Feb 19  2014 NET-SNMP-MONITOR-MIB.txt
-rw-r--r-- 1 root root  3350 Feb 19  2014 NET-SNMP-PASS-MIB.txt
-rw-r--r-- 1 root root  2504 Feb 19  2014 NET-SNMP-PERIODIC-NOTIFY-MIB.txt
-rw-r--r-- 1 root root  1226 Feb 19  2014 NET-SNMP-SYSTEM-MIB.txt
-rw-r--r-- 1 root root  4814 Feb 19  2014 NET-SNMP-TC.txt
-rw-r--r-- 1 root root  5039 Feb 19  2014 NET-SNMP-VACM-MIB.txt
-rw-r--r-- 1 root root 43927 Feb 19  2014 SNMP-TLS-TM-MIB.txt
-rw-r--r-- 1 root root  8912 Feb 19  2014 SNMP-TSM-MIB.txt
-rw-r--r-- 1 root root  2163 Feb 19  2014 UCD-DEMO-MIB.txt
-rw-r--r-- 1 root root  4613 Feb 19  2014 UCD-DISKIO-MIB.txt
-rw-r--r-- 1 root root  3087 Feb 19  2014 UCD-DLMOD-MIB.txt
-rw-r--r-- 1 root root  6476 Feb 19  2014 UCD-IPFILTER-MIB.txt
-rw-r--r-- 1 root root  8118 Feb 19  2014 UCD-IPFWACC-MIB.txt
-rw-r--r-- 1 root root 18274 Feb 19  2014 UCD-SNMP-MIB-OLD.txt
-rw-r--r-- 1 root root 48890 Feb 19  2014 UCD-SNMP-MIB.txt
(Philipp Näther) #7

check_mk does not use MIB files. It doesn’t matter which MIBs you have got installed on your system and which not.

I would say your router does not provide correct qos information. Did it get any firmware updates lately?

(Tobias Grossmann) #8

at the commandline help (cmk --?) there I found this here:

–snmpwalk Does a complete snmpwalk for the specified hosts both on the
standard MIB and the enterprises MIB and stores the result in the directory
‘/omd/sites/psgmon/var/check_mk/snmpwalks’. Use the option --oid one or
several times in order to specify alternative OIDs to walk. You need to
specify numeric OIDs. If you want to keep the two standard OIDS .1.3.6.1.2.1
and .1.3.6.1.4.1 then use --extraoid for just adding additional OIDs to
walk.

If I do a snmpwalk, there are only 1.3.6.1.2.1 OIDs in the output, could it be settings-problem of my cmk?

(Philipp Näther) #9

I don’t think so. If it is a general problem, all your other vendor specific snmp checks wouldn’t work aswell.
The OIDs cmk is looking for in its snmp scan functions are defined within the check plugins.

Please do a walk on this OID:

.1.3.6.1.4.1.9.9.166.1.5.1.1.2

(Tobias Grossmann) #10

worx fine, but not without that OID:

root@Monitoring:~# snmpwalk -v1 -c community IP-Address .1.3.6.1.4.1.9.9.166.1.5.1.1.2
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.1 = Gauge32: 87514055
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.65536 = Gauge32: 1593
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.65537 = Gauge32: 1594
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.65538 = Gauge32: 1379036520
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.131072 = Gauge32: 35008277
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.196608 = Gauge32: 330149229
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.196609 = Gauge32: 585247253
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.196610 = Gauge32: 868775843
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.196611 = Gauge32: 1881723036
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.262144 = Gauge32: 331335087
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.262145 = Gauge32: 548897538
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.262146 = Gauge32: 665106194
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.262147 = Gauge32: 917164217
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.262148 = Gauge32: 1988716163
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.327680 = Gauge32: 328180335
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.327681 = Gauge32: 537327710
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.327682 = Gauge32: 599555553
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.327683 = Gauge32: 928951593
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.327684 = Gauge32: 1959778339
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.393216 = Gauge32: 324864002
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.393217 = Gauge32: 638370397
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.393218 = Gauge32: 604442483
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.393219 = Gauge32: 815494512
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.393220 = Gauge32: 1976141403
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.458752 = Gauge32: 1593
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.458753 = Gauge32: 1594
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.458754 = Gauge32: 1166881592
iso.3.6.1.4.1.9.9.166.1.5.1.1.2.130.458755 = Gauge32: 1912629469

(Philipp Näther) #11

Now do a walk on this OID.

Edit: No, this one, sry:

.1.3.6.1.4.1.9.9.166.1.1.1.1.4.130

(Tobias Grossmann) #12

iso.3.6.1.4.1.9.9.166.1.1.1.1.4.130 = INTEGER: 8

(Philipp Näther) #13

Now walk this OID to see if the router provides a correct interface description of a connected if port:

.1.3.6.1.2.1.31.1.1.1.1.8

(Tobias Grossmann) #14

Yes:

iso.3.6.1.2.1.31.1.1.1.1.8 = STRING: “Gi0/0/0.1”

(Philipp Näther) #15

Well ok. Seems like the main information is provided by the router. I would now proceed to debug the error with help of the check plugin. But it is hard to do this here for further help with your issue :confused:

(Tobias Grossmann) #16

Ok… :frowning:
could you maybe tell me, which logfile i have to look in, which commend i have to do( cmk -nv?) and where the config-file is, so that i can try it myself?

(Philipp Näther) #17

Commands you can debug with are cmk --debug -II and cmk --debug -nv.
The plugin file is ~/share/check_mk/checks/cisco_qos. You could add several print to check what is happening in the inventory function.
Unfortunately there is no log file you could check.

(Tobias Grossmann) #18

ok, thank you, i will test something.

Maybe the Plugin is wrong, because the router provides the OIDs with the prefix “iso.3.6.” and the Plugin lokks at “.1.3.6”:

do I have to do a cmk -C after changing the Plugin?

(Philipp Näther) #19

The partial translation of the OID is done on your server. A SNMP device does never provide translated OIDs, only numeric. Just ignore it :wink:

No, just try to understand and debug the inventory function and the info. After every change you can simply run a cmk -II HOST and you should see the changes you made in the plugin.

(Tobias Grossmann) #20

ok, thank you. One last question :wink:

nothing is differnet on the output, from cmk -nv to cmk --debug -nv? is there a logfile?