check_swap
Posted by tonvoon on 8 December 2007 - 1:26am
check_swap v1613 (nagios-plugins 1.4.10)
Copyright (c) 2000-2006 Nagios Plugin Development Team
<nagiosplug-devel@lists.sourceforge.net>
Check swap space on local machine.
Usage:check_swap [-av] -w <percent_free>% -c <percent_free>%
check_swap [-av] -w <bytes_free> -c <bytes_free>
Options:
-h, --help
Print detailed help screen
-V, --version
Print version information
-w, --warning=INTEGER
Exit with WARNING status if less than INTEGER bytes of swap space are free
-w, --warning=PERCENT%%
Exit with WARNING status if less than PERCENT of swap space is free
-c, --critical=INTEGER
Exit with CRITICAL status if less than INTEGER bytes of swap space are free
-c, --critical=PERCENT%%
Exit with CRITCAL status if less than PERCENT of swap space is free
-a, --allswaps
Conduct comparisons for all swap partitions, one by one
-v, --verbose
Verbose output. Up to 3 levels
Notes:
On AIX, if -a is specified, uses lsps -a, otherwise uses lsps -s.
Send email to nagios-users@lists.sourceforge.net if you have questions
regarding use of this software. To submit patches or suggest improvements,
send email to nagiosplug-devel@lists.sourceforge.net
- Printer-friendly version
- Login or register to post comments
Hello,
i struggling with check_swap in my cfg. It looks like:
# Define a service to check Swap
define service{
use generic-service
host_name Gandalf
service_description DHCP Check
check_command check_swap!30
}
It is not abel to run. The result:
root@Gandalf:/etc/nagios3/conf.d# /etc/init.d/nagios3 start
* Starting nagios3 monitoring daemon nagios3
Nagios 3.0.6
Copyright (c) 1999-2008 Ethan Galstad (http://www.nagios.org)
Last Modified: 12-01-2008
License: GPL
Reading configuration data...
Running pre-flight check on configuration data...
Checking services...
Error: Service check command 'check_swap' specified in service 'swap Check' for host 'Gandalf' not defined anywhere!
Checked 15 services.
Checking hosts...
Warning: Host 'Outside' has no services associated with it!
Checked 5 hosts.
Checking host groups...
Checked 5 host groups.
Checking service groups...
Checked 0 service groups.
Checking contacts...
Checked 1 contacts.
Checking contact groups...
Checked 1 contact groups.
Checking service escalations...
Checked 0 service escalations.
Checking service dependencies...
Checked 0 service dependencies.
Checking host escalations...
Checked 0 host escalations.
Checking host dependencies...
Checked 0 host dependencies.
Checking commands...
Checked 192 commands.
Checking time periods...
Checked 4 time periods.
Checking for circular paths between hosts...
Checking for circular host and service dependencies...
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...
Total Warnings: 1
Total Errors: 1
***> One or more problems was encountered while running the pre-flight check...
Check your configuration file(s) to ensure that they contain valid
directives and data defintions. If you are upgrading from a previous
version of Nagios, you should be aware that some variables/definitions
may have been removed or modified in this version. Make sure to read
the HTML documentation regarding the config files, as well as the
'Whats New' section to find out what has changed.
* errors in config!
[fail]
Could you help me? The reason is this:
Error: Service check command 'check_swap' specified in service 'swap Check' for host 'Gandalf' not defined anywhere!
But tel me where i must define "swap Check" i suggest it is a comment in the description... or is't it?
Thanks a lot
Best regards, Klaus