From e4d78ce330bb18f4474efdc2200bc53b1197cf4d Mon Sep 17 00:00:00 2001 From: Michal Moravec Date: Thu, 31 Oct 2019 16:15:10 +0100 Subject: [PATCH] Implement check_snmp_int.pl -q extended checks --- doc/10-icinga-template-library.md | 1 + itl/command-plugins-manubulon.conf | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/doc/10-icinga-template-library.md b/doc/10-icinga-template-library.md index 91c3c23a4..e8f3ec918 100644 --- a/doc/10-icinga-template-library.md +++ b/doc/10-icinga-template-library.md @@ -2069,6 +2069,7 @@ snmp_interface_kbits | **Optional.** Make the warning and critical levels snmp_interface_megabytes | **Optional.** Make the warning and critical levels in Mbps or MBps. **Depends** on snmp_interface_kbits set to true. Defaults to true. snmp_interface_64bit | **Optional.** Use 64 bits counters instead of the standard counters when checking bandwidth & performance data for interface >= 1Gbps. Defaults to false. snmp_interface_errors | **Optional.** Add error & discard to Perfparse output. Defaults to true. +snmp_interface_extended_checks | **Optional.** Also check the error and discard input/output. Defaults to false. snmp_interface_noregexp | **Optional.** Do not use regexp to match interface name in description OID. Defaults to false. snmp_interface_delta | **Optional.** Delta time of perfcheck. Defaults to "300" (5 min). snmp_interface_warncrit_percent | **Optional.** Make the warning and critical levels in % of reported interface speed. If set, **snmp_interface_megabytes** needs to be set to false. Defaults to false. diff --git a/itl/command-plugins-manubulon.conf b/itl/command-plugins-manubulon.conf index 910a4ceae..3c6b8f137 100644 --- a/itl/command-plugins-manubulon.conf +++ b/itl/command-plugins-manubulon.conf @@ -271,6 +271,10 @@ object CheckCommand "snmp-interface" { set_if = "$snmp_interface_errors$" description = "Add error & discard to Perfparse output" } + "-q" = { + set_if = "$snmp_interface_extended_checks$" + description = "Also check the error and discard input/output" + } "-i" = { set_if = "$snmp_interface_inverse$" description = "Make critical when up" @@ -311,6 +315,7 @@ object CheckCommand "snmp-interface" { vars.snmp_interface_megabytes = true vars.snmp_interface_64bit = false vars.snmp_interface_errors = true + vars.snmp_interface_extended_checks = false vars.snmp_interface_noregexp = false vars.snmp_interface_delta = 300 vars.snmp_interface_warncrit_percent = false