Module: check_mk
Branch: master
Commit: fa28d378ce878d2e11a3389746390faa90702382
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=fa28d378ce878d…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Mon Jan 2 17:43:56 2012 +0100
Fix levels in trend perfdata
---
checks/df.include | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/checks/df.include b/checks/df.include
index 10ff062..a2abc8a 100644
--- a/checks/df.include
+++ b/checks/df.include
@@ -222,8 +222,10 @@ def df_check_filesystem(hostname, mountpoint, size_mb, avail_mb,
params):
# MB / 24 hours. The same holds for the warn and crit information.
# It is configured in MB / trend range but in the performance data
# it's sent as MB / 24h.
- perfdata.append(("trend", rate_avg * H24, warn_perf / range_sec
* H24,
- crit_perf / range_sec * H24, 0, size_mb / range))
+ perfdata.append(("trend", rate_avg * H24,
+ warn_perf != None and (warn_perf / range_sec * H24) or
None,
+ crit_perf != None and (crit_perf / range_sec * H24) or
None,
+ 0, size_mb / range))
# compute time until filesystem is full (only for positive trend, of course)
if trend > 0: