nagios sample object config file for monitoring machines.
First you need to have the
Host definition — > Host group definition [here we add the hosts for this group]–>and then the Service Definition
Example: for Service Definition
# Define a service to check the disk space of the root partition
# on the local machine. Warning if < 20% free, critical if # < 10% free space on partition.
define service{
use local-service ; Name of service template to use
host_name localhost
service_description Root Partition
check_command check_local_disk!20%!10%!/
}
# Define a service to check HTTP on the local machine.
# Disable notifications for this service by default, as not all users may have HTTP enabled.
define service{
use local-service ; Name of service template to use
host_name serversignature.com
service_description HTTP
check_command check_http
}