disk checks unreliable

Tim Dunphy bluethundr at jokefire.com
Thu Oct 6 04:52:20 CEST 2011


hello list!

 hello.. I am running a nagios disk check that reports OK even when the partition is not mounted or the machine is shut down .. how can I test the check and adjust it so that it reports accurately?


## Machine info

CentOS release 5.6 (Final)
i686

##Nagios Version

Nagios Core 3.3.1

## Command definition

define command{
        command_name    check_store_disk
        command_line    $USER1$/check_disk -w $ARG1$ -c $ARG2$ -p $ARG3$
        }


## Service definition

define service{
        use                             local-service         ; Name of service template to use
        #host_name                       localhost
        hostgroup_name                  web-servers
        service_description             Store Partition
        check_command                   check_store_disk!20%!10%!/
        }

The disk is mounted:

[root at VIRTCENT11:~] #df -h
nas2:/mnt/store
                      1.4T  370G  876G  30% /mnt/store

[root at VIRTCENT11:~] #/usr/local/nagios/libexec/check_disk -w 20% -c 10% -p /mnt/store
DISK OK - free space: /mnt/store 896088 MB (70% inode=99%);| /mnt/store=378829MB;1108624;1247202;0;1385780

In this case the check is accurate...the disk is mounted

Now I unmount the partition:

[root at VIRTCENT11:~] #umount /mnt/store

I verify that the partition is not mounted with df and then run the check again:

[root at VIRTCENT11:~] #/usr/local/nagios/libexec/check_disk -w 20% -c 10% -p /mnt/store
DISK OK - free space: / 5737 MB (68% inode=96%);| /=2581MB;7017;7894;0;8772

But the check still thinks the disk is ok. 

How can I best address this problem?

Thank you,
Tim


------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2dcopy1
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list