Module: check_mk
Branch: master
Commit: fde25d75b9aef0b1a0eb70888107a22eb2d1dace
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=fde25d75b9aef0…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Thu Dec 5 16:58:33 2013 +0100
FIX borcade_mlx_fan: Prettified output, handling "other" state now
---
.werks/299 | 8 ++++++++
ChangeLog | 3 +++
checks/brocade_mlx_fan | 8 +++++---
3 files changed, 16 insertions(+), 3 deletions(-)
diff --git a/.werks/299 b/.werks/299
new file mode 100644
index 0000000..82cf055
--- /dev/null
+++ b/.werks/299
@@ -0,0 +1,8 @@
+Title: borcade_mlx_fan: Prettified output, handling "other" state now
+Level: 1
+Component: checks
+Version: 1.2.3i8
+Date: 1386259077
+Class: fix
+
+
diff --git a/ChangeLog b/ChangeLog
index 4eeca4e..36bb941 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,7 @@
1.2.3i8:
+ Checks & Agents:
+ * 0299 FIX: borcade_mlx_fan: Prettified output, handling "other" state now
+
1.2.3i7:
Core & Setup:
diff --git a/checks/brocade_mlx_fan b/checks/brocade_mlx_fan
index 12af935..c165bb0 100644
--- a/checks/brocade_mlx_fan
+++ b/checks/brocade_mlx_fan
@@ -49,11 +49,13 @@ def check_brocade_mlx_fan(item, _no_params, info):
for fan_id, fan_descr, fan_state in info:
if combine_item(fan_id, fan_descr) == item:
if fan_state == "2":
- return 0, "Fan reports status 2 (normal)"
+ return 0, "Fan reports state: normal"
elif fan_state == "3":
- return 2, "Fan reports status 3 (failure)"
+ return 2, "Fan reports state: failure"
+ elif fan_state == "1":
+ return 3, "Fan reports state: other"
else:
- return 3, "Fan reports unidentified status %s" % fan_state
+ return 3, "Fan reports an unknown state (%s)" % fan_state
return 3, "Fan %s not found" % item
check_info["brocade_mlx_fan"] = {