NAME

check_disk - disk space client check modules


DESCRIPTION

This is a client check that is run by spong-client that checks disk space and swap space on the client host. check_disk  uses the output of the df command by checking the percentage of space used by each mounted file system. The percentage of space used is checked against %DFWARN and %DFCRIT levels to generate an appropirate  yellow or red status.

Swap space is also checked by using the &get_swap() function which returns a message and a percentage of total space space used. This percentage is checked against the $DFWARN{'page'} and $DFCRIT{'page'} entry levels to generate an appropriate yellow or red status.
 

OUTPUT RETURNED

SUMMARY MESSAGE FIELD
If all statuses are green, check_disk returns the largest file system in use. Otherwise If any file systems are in red status, a list all of the mount points with the percent of space used is returned.

DETALED MESSAGE FIELD
The output of the df command and the message returned by the &get_swap function are returned.
 

CONFIGURATION

Here is a list of all of the configuration variables used by check_disk.
@DFIGNORE
A list of regular expression strings that are matched against the raw file system names. If matched, then that file system is ignored. For example, having ``:'' in this list will cause NFS file system mounts to be ignored.

%DFWARN, %DFCRIT
A hash of file systems (or the word ``ALL''), and the percentage that should trigger a problem (%DFWARN triggers warnings - yellow, and %DFCRIT triggers alerts - red). If a file system is not explicitly listed in this hash then it will fall back to the value of the ``ALL'' entry.

$DF
An OS specific variable that contains the path to the df command  and paramters to be run to get file systems used information.

&get_swap()
An OS specific function that get the total space space usage information. It returns two paramaters: message - a strings containing the swap usage information to be returned in the detail message field of the status message, and total_swap - a percentage of the total amount of space space in use.
 

FILES
/usr/local/etc/spong/spong.conf
Configuration file. This contains variables that detail spong and OS specific definitions used by spong-client. This file also contain variables describing threshold levels. See spong.conf for additional documentation.
AUTHOR

Stephen L Johnson (stephen.johnson@mail.state.ar.us) or (sjohnson@monsters.org), Unix System Administator, DIS - State of Arkansas