summaryrefslogtreecommitdiffstats
path: root/web/attachments/210121-check_disk.multiple_perfdata.patch
diff options
context:
space:
mode:
authorHolger Weiss <holger@zedat.fu-berlin.de>2013-09-29 22:03:24 (GMT)
committerHolger Weiss <holger@zedat.fu-berlin.de>2013-09-29 22:03:24 (GMT)
commit0b6423f9c99d9edf8c96fefd0f6c453859395aa1 (patch)
tree1c2b6b21704a294940f87c7892676998d8371707 /web/attachments/210121-check_disk.multiple_perfdata.patch
downloadsite-0b6423f9c99d9edf8c96fefd0f6c453859395aa1.tar.gz
Import Nagios Plugins site
Import the Nagios Plugins web site, Cronjobs, infrastructure scripts, and configuration files.
Diffstat (limited to 'web/attachments/210121-check_disk.multiple_perfdata.patch')
-rw-r--r--web/attachments/210121-check_disk.multiple_perfdata.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/web/attachments/210121-check_disk.multiple_perfdata.patch b/web/attachments/210121-check_disk.multiple_perfdata.patch
new file mode 100644
index 0000000..bf2d265
--- /dev/null
+++ b/web/attachments/210121-check_disk.multiple_perfdata.patch
@@ -0,0 +1,30 @@
1Index: plugins/check_disk.c
2===================================================================
3RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_disk.c,v
4retrieving revision 1.81
5diff -u -r1.81 check_disk.c
6--- plugins/check_disk.c 20 Dec 2006 19:25:59 -0000 1.81
7+++ plugins/check_disk.c 7 Jan 2007 07:01:22 -0000
8@@ -164,8 +164,8 @@
9 double dfree_pct = -1, dused_pct = -1;
10 double dused_units, dfree_units, dtotal_units;
11 double dused_inodes_percent, dfree_inodes_percent;
12- double warning_high_tide = UINT_MAX;
13- double critical_high_tide = UINT_MAX;
14+ double warning_high_tide;
15+ double critical_high_tide;
16 int temp_result;
17
18 struct mount_entry *me;
19@@ -300,6 +300,11 @@
20 Hack here. Trying to get warn/crit levels from freespace_(units|percent) for perf
21 data. Assumption that start=0. Roll on new syntax...
22 */
23+
24+ /* *_high_tide must be reinitialized at each run */
25+ warning_high_tide = UINT_MAX;
26+ critical_high_tide = UINT_MAX;
27+
28 if (path->freespace_units->warning != NULL) {
29 warning_high_tide = dtotal_units - path->freespace_units->warning->end;
30 }