diff options
author | Ton Voon <tonvoon@users.sourceforge.net> | 2003-03-08 12:08:24 +0000 |
---|---|---|
committer | Ton Voon <tonvoon@users.sourceforge.net> | 2003-03-08 12:08:24 +0000 |
commit | e5785a500037649a286f927586416bbdf14c7424 (patch) | |
tree | f731160b2461d55af6dc126b68ee6b7a0f2dfcf3 /plugins/check_disk.c | |
parent | fd0a7d3b5a206dd98f339d4d76b6b92be0b89090 (diff) | |
download | monitoring-plugins-e5785a500037649a286f927586416bbdf14c7424.tar.gz |
Fix AIX /proc filesystem (Ian Duggan)
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@387 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins/check_disk.c')
-rw-r--r-- | plugins/check_disk.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/check_disk.c b/plugins/check_disk.c index 3c1cfef9..feeff560 100644 --- a/plugins/check_disk.c +++ b/plugins/check_disk.c @@ -15,7 +15,7 @@ * currently mounted filesystems. If the percent used disk space is * above <c_dfp>, a STATE_CRITICAL is returned. If the percent used * disk space is above <w_dfp>, a STATE_WARNING is returned. If the - * speicified filesystem cannot be read, a STATE_CRITICAL is returned, + * specified filesystem cannot be read, a STATE_CRITICAL is returned, * other errors with reading the output result in a STATE_UNKNOWN * error. * @@ -96,6 +96,10 @@ main (int argc, char **argv) if (!index (input_buffer, '/')) continue; + /* Fixes AIX /proc fs which lists - for size values */ + if (strstr (input_buffer, "/proc ") == input_buffer) + continue; + if (sscanf (input_buffer, "%s %d %d %d %d%% %s", file_system, &total_disk, &used_disk, &free_disk, &usp, mntp) == 6 || sscanf (input_buffer, "%s %*s %d %d %d %d%% %s", file_system, |