Module: check_mk
Branch: master
Commit: 515d60c49c5513bf9c3ef04352aeb89e651fd3d8
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=515d60c49c5513…
Author: Bastian Kuhn <bk(a)mathias-kettner.de>
Date: Mon Jan 13 14:28:43 2014 +0100
FIX stulz_humidity: Fixed lower thresholds
The check thresholds for warning produced critical before.
---
.werks/119 | 9 +++++++++
ChangeLog | 1 +
checks/stulz_humidity | 6 +++---
3 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/.werks/119 b/.werks/119
new file mode 100644
index 0000000..cbe2033
--- /dev/null
+++ b/.werks/119
@@ -0,0 +1,9 @@
+Title: stulz_humidity: Fixed lower thresholds
+Level: 1
+Component: checks
+Class: fix
+State: unknown
+Version: 1.2.5i1
+Date: 1389619595
+
+The check thresholds for warning produced critical before.
diff --git a/ChangeLog b/ChangeLog
index b59c261..55e2acc 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -96,6 +96,7 @@
* 0444 FIX: timemachine: do not inventorize check when timemachine is not used
* 0116 FIX: cisco_vpn_tunnel: Fixed typo that lead to an exception
* 0118 FIX: stulz_humidity: Fixed coloring in pnp template...
+ * 0119 FIX: stulz_humidity: Fixed lower thresholds...
Multisite:
* 0371 Added log class filter to hostsvcevents view
diff --git a/checks/stulz_humidity b/checks/stulz_humidity
index bf1bcba..dad7c61 100644
--- a/checks/stulz_humidity
+++ b/checks/stulz_humidity
@@ -42,12 +42,12 @@ def check_stulz_humidity(item, params, info):
elif humidity >= warnhigh:
state = 1
msg = "to high (Levels Warning/Critical %d/%d) " % ( warnhigh,
crithigh )
+ elif humidity <= warnlow and humidity > critlow:
+ state = 1
+ msg = "to low (Levels Warning/Critical %d/%d) " % ( warnlow,
critlow )
elif humidity <= critlow:
state = 2
msg = "to low (Levels Warning/Critical %d/%d) " % ( warnlow,
critlow )
- elif humidity <= warnlow:
- state = 1
- msg = "to low (Levels Warning/Critical %d/%d) " % ( warnlow,
critlow )
message = " Current Humidity: %.2f%% %s" % ( humidity, msg )
perf = [ ('humidity', humidity, critlow, warnlow, warnhigh, crithigh
) ]
return state, message, perf