summaryrefslogtreecommitdiffstats
path: root/web/attachments/41661-check_disk.patch
diff options
context:
space:
mode:
Diffstat (limited to 'web/attachments/41661-check_disk.patch')
-rw-r--r--web/attachments/41661-check_disk.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/web/attachments/41661-check_disk.patch b/web/attachments/41661-check_disk.patch
new file mode 100644
index 0000000..ef6ce3e
--- /dev/null
+++ b/web/attachments/41661-check_disk.patch
@@ -0,0 +1,30 @@
1Index: check_disk.c
2===================================================================
3RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_disk.c,v
4retrieving revision 1.7
5diff -r1.7 check_disk.c
630a31,32
7> * - Modification by www.datux.nl 2003-01-24
8> * added performance data output
966a69,71
10> int perf_total_disk = 0;
11> int perf_free_disk = 0;
12> int perf_used_disk = 0;
1398a104
14> /* did we get some usefull output from the 'df' process? */
15120a127,129
16> perf_total_disk+=total_disk;
17> perf_free_disk+=free_disk;
18> perf_used_disk+=used_disk;
19150,151c159,166
20< printf ("DISK %s%s\n", state_text (result), output);
21<
22---
23> printf ("DISK %s%s|total=%d,used=%d,free=%d,used_perc=%f,free_perc=%f\n",
24> state_text (result),
25> output,
26> perf_total_disk,
27> perf_used_disk,
28> perf_free_disk,
29> 100-((float)perf_free_disk*100/(float)perf_total_disk),
30> ((float)perf_free_disk*100/(float)perf_total_disk));