<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Hari,<br>
<br>
Works fine here (this is on Fedora 4) - check_disk (nagios-plugins
1.4.5) 1.79:<br>
<br>
[NetServe@cooma ~]$ df -h<br>
Filesystem Size Used Avail Use% Mounted on<br>
/dev/hda1 12G 1.4G 10G 13% /<br>
/dev/hda5 4.6G 33M 4.4G 1% /tmp<br>
/dev/hda6 56G 912M 52G 2% /endeavour<br>
none 247M 0 247M 0% /dev/shm<br>
[NetServe@cooma ~]$ sudo -u nagios /usr/local/nagios/libexec/check_disk
-w 20% -c 10% -p /<br>
DISK OK - free space: / 10180 MB (87% inode=96%);|
/=1406MB;9764;10985;0;12206<br>
[NetServe@cooma ~]$ sudo -u nagios /usr/local/nagios/libexec/check_disk
-w 90% -c 10% -p /<br>
DISK WARNING - free space: / 10180 MB (87% inode=96%);|
/=1406MB;1220;10985;0;12206<br>
[NetServe@cooma ~]$ sudo -u nagios /usr/local/nagios/libexec/check_disk
-w 95% -c 90% -p /<br>
DISK CRITICAL - free space: / 10180 MB (87% inode=96%);|
/=1406MB;610;1220;0;12206<br>
<br>
Even with the megabytes switch (-m):<br>
<br>
[NetServe@cooma ~]$ sudo -u nagios /usr/local/nagios/libexec/check_disk
-w 10100 -c 10000 -m -p /<br>
DISK OK - free space: / 10180 MB (87% inode=96%);|
/=1406MB;2106;2206;0;12206<br>
[NetServe@cooma ~]$ sudo -u nagios /usr/local/nagios/libexec/check_disk
-w 10190 -c 10000 -m -p /<br>
DISK WARNING - free space: / 10180 MB (87% inode=96%);|
/=1406MB;2016;2206;0;12206<br>
[NetServe@cooma ~]$ sudo -u nagios /usr/local/nagios/libexec/check_disk
-w 12000 -c 11000 -m -p /<br>
DISK CRITICAL - free space: / 10180 MB (87% inode=96%);|
/=1406MB;206;1206;0;12206<br>
<br>
Have you tried the latest version of the plugins?<br>
<br>
Andy.<br>
<br>
<br>
Hari Sekhon wrote:
<blockquote cite="mid45D347A8.4070002@googlemail.com" type="cite">
<pre wrap="">OK it's not just a bug with the -m switch but with the whole plugin.
Observe:
/usr/nagios/libexec/check_disk -l -w 2 -c 1 -u TB -vvv
DISK OK - free space: / 0 TB (77% inode=98%); /dev 0 TB (100%
inode=98%); /home/match/ramdisk 0 TB (17% inode=100%); /dev/shm 0 TB
(100% inode=100%); /boot 0 TB (93% inode=100%);
0 of 0 TB (77% inode=98%) free on /dev/sda2 (type ext3 mounted on /)
warn:2 crit:1 warn%:-1% crit%:-1%
0 of 0 TB (100% inode=98%) free on udev (type tmpfs mounted on /dev)
warn:2 crit:1 warn%:-1% crit%:-1%
0 of 0 TB (17% inode=100%) free on tmpfs (type tmpfs mounted on
/home/match/ramdisk) warn:2 crit:1 warn%:-1% crit%:-1%
0 of 0 TB (100% inode=100%) free on shm (type tmpfs mounted on /dev/shm)
warn:2 crit:1 warn%:-1% crit%:-1%
0 of 0 TB (93% inode=100%) free on /dev/sda1 (type ext3 mounted on
/boot) warn:2 crit:1 warn%:-1% crit%:-1%| /=0TB;0;0;98;0
/dev=0TB;0;0;97;0 /home/match/ramdisk=0TB;0;0;99;0 /dev/shm=0TB;0;0;99;0
/boot=0TB;0;0;99;0
Hari Sekhon
Hari Sekhon wrote:
</pre>
<blockquote type="cite">
<pre wrap="">I'm using check disk and want to have it test the filesystem of a
mount point rather than a partition.
# df /
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda2 153337060 28240084 117307864 20% /
DF shows the filesystem is 20% used so I want this to force an error
using the following test line so see that it actually works:
check_disk -m / -w 90%
the above check_disk should show Warning at this point as there is
less than 90% free space left. Whether I do 10% or 90% it still
returns successful even when it's not in the threshold range.
# /usr/nagios/libexec/check_disk -m /home -w 100%
DISK OK - free space: / 114558 MB (77% inode=98%);|
/=35185MB;149743;149743;98;149743
# /usr/nagios/libexec/check_disk -m /home -w 10%
DISK OK - free space: / 114558 MB (77% inode=98%);|
/=35185MB;149743;149743;98;149743
# /usr/nagios/libexec/check_disk -m /home -w 90%
DISK OK - free space: / 114558 MB (77% inode=98%);|
/=35185MB;149743;149743;98;149743
The same is true when I was testing the /boot partition (which is a
separate partition). So it looks like the -m switch is broken.
Can anyone verify this? Is it a known bug, is it fixed?
I am running "check_disk (nagios-plugins 1.4.3) 1.64" (taken from the
top line of check_disk --help)
</pre>
</blockquote>
<pre wrap=""><!---->
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
<a class="moz-txt-link-freetext" href="http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV">http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV</a>
_______________________________________________
Nagios-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a>
<a class="moz-txt-link-freetext" href="https://lists.sourceforge.net/lists/listinfo/nagios-users">https://lists.sourceforge.net/lists/listinfo/nagios-users</a>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
!DSPAM:37,45d347e218511427819843!
</pre>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="72">--
Andy Shellam
NetServe Support Team
the Mail Network
"an alternative in a standardised world"
p: +44 (0) 121 288 0832/0839
m: +44 (0) 7818 000834</pre>
</body>
</html>