summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTon Voon <tonvoon@users.sourceforge.net>2003-06-25 12:38:37 (GMT)
committerTon Voon <tonvoon@users.sourceforge.net>2003-06-25 12:38:37 (GMT)
commit0651464f597e1b702e954ef2cccf9ccf15148f44 (patch)
tree5f49b92b90fc3db58344cb9e3c1e745e0723275c
parent535786e685c1380a0a54ab88f6b80ef8fd5e8d52 (diff)
downloadmonitoring-plugins-0651464f597e1b702e954ef2cccf9ccf15148f44.tar.gz
Returns critical if fs missing. Only works for single fs specified in -p,
otherwise will return warning as before (reported by Jim Carroll) git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/branches/release-1.3.0@553 f882894a-f735-0410-b71e-b25c423dba1c
-rw-r--r--plugins/check_disk.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/check_disk.c b/plugins/check_disk.c
index 9421d06..234a09d 100644
--- a/plugins/check_disk.c
+++ b/plugins/check_disk.c
@@ -150,8 +150,10 @@ main (int argc, char **argv)
150 if (spclose(child_process)!=0 && result!=STATE_CRITICAL) 150 if (spclose(child_process)!=0 && result!=STATE_CRITICAL)
151 result = STATE_WARNING; 151 result = STATE_WARNING;
152 152
153 if (usp < 0) 153 if (usp < 0) {
154 printf ("Disk \"%s\" not mounted or nonexistant\n", path); 154 printf ("Disk \"%s\" not mounted or nonexistant\n", path);
155 result = STATE_CRITICAL;
156 }
155 else if (result == STATE_UNKNOWN) 157 else if (result == STATE_UNKNOWN)
156 printf ("Unable to read output\n%s\n%s\n", command_line, input_buffer); 158 printf ("Unable to read output\n%s\n%s\n", command_line, input_buffer);
157 else 159 else