Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
check_host_services
Meet The New Nagios Core Services Platform
Built on over 25 years of monitoring experience, the Nagios Core Services Platform provides insightful monitoring dashboards, time-saving monitoring wizards, and unmatched ease of use. Use it for free indefinitely.
Monitoring Made Magically Better
- Nagios Core on Overdrive
- Powerful Monitoring Dashboards
- Time-Saving Configuration Wizards
- Open Source Powered Monitoring On Steroids
- And So Much More!
This host check will check all services belonging to a host.
If all are OK, the host is UP.
If one or more are in warning/critical the host will be DOWN.
You can use the following command definition:
define command {
command_name check_host_services
command_line $USER1$/check_host_services -H $HOSTNAME$ --mode=all
}
Note the $HOSTNAME$ macro!
Credits where credit is due:
I'm using the perl modules located here:
http://exchange.nagios.org/directory/Addons/APIs/Perl/Nagios-3A-3AStatus-3A-3A*/details
Since they also allow me to easily get the OK checks.
versions:
2.0:
- switched to Nagios::Status::* framework
- rewrote entire code to have it a bit cleaner
- added a mode option to select any or all.
- all: all checks must be OK or host is down.
- any: if all checks are in a state other than ok, the host is down.
- added performance data
1.0:
- initial release
If all are OK, the host is UP.
If one or more are in warning/critical the host will be DOWN.
You can use the following command definition:
define command {
command_name check_host_services
command_line $USER1$/check_host_services -H $HOSTNAME$ --mode=all
}
Note the $HOSTNAME$ macro!
Credits where credit is due:
I'm using the perl modules located here:
http://exchange.nagios.org/directory/Addons/APIs/Perl/Nagios-3A-3AStatus-3A-3A*/details
Since they also allow me to easily get the OK checks.
versions:
2.0:
- switched to Nagios::Status::* framework
- rewrote entire code to have it a bit cleaner
- added a mode option to select any or all.
- all: all checks must be OK or host is down.
- any: if all checks are in a state other than ok, the host is down.
- added performance data
1.0:
- initial release
Reviews (1)
byhomelyn, January 11, 2012
This is what i was waiting for a long time. Thanks,