Module: check_mk
Branch: master
Commit: 3557e16a2de7bca81743ff13ba55d103decccf17
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=3557e16a2de7bc…
Author: Simon Betz <si(a)mathias-kettner.de>
Date: Tue Jul 18 09:43:31 2017 +0200
4978 FIX ipmi: Ignore sensors with state 'na'
Change-Id: Ic3ef308b708ff6b4c0f663117e24664b90d6f26c
---
.werks/4978 | 11 +++++++++++
checks/ipmi | 4 ++--
2 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/.werks/4978 b/.werks/4978
new file mode 100644
index 0000000..a572903
--- /dev/null
+++ b/.werks/4978
@@ -0,0 +1,11 @@
+Title: ipmi: Ignore sensors with state 'na'
+Level: 1
+Component: checks
+Class: fix
+Compatible: compat
+Edition: cre
+State: unknown
+Version: 1.5.0i1
+Date: 1500363777
+
+
diff --git a/checks/ipmi b/checks/ipmi
index 8d2b874..8f03aba 100644
--- a/checks/ipmi
+++ b/checks/ipmi
@@ -193,7 +193,7 @@ def parse_ipmi(info):
inventory_ipmi_rules = []
factory_settings["ipmi_default_levels"] = {
- "ignored_sensorstates" : [ "ns", "nr" ]
+ "ignored_sensorstates" : [ "ns", "nr", "na"
]
}
@@ -222,7 +222,7 @@ def inventory_ipmi(info):
elif type(rules[0]) == tuple:
single_rules = rules[0][1].copy()
if "ignored_sensorstates" not in single_rules:
- single_rules["ignored_sensorstates"] = [ "ns",
"nr" ]
+ single_rules["ignored_sensorstates"] = [ "ns",
"nr", "na" ]
for sensorname, data in parsed.items():
if not ipmi_ignore_entry(sensorname, data["status_txt"],
single_rules):
yield sensorname, {}