参考文档:
1. 修改:/usr/local/nagios/etc/nagios.cfg 增加(后面的文件):
cfg_file=/usr/local/nagios/etc/objects/service.cfg
2. nsca 的log:
/var/log/messages
配置文件对象之间的关系(与具体在那个文件中没有关系):
service --use--> Other Service --defined in --> template.cfg (define Services)
:host_name --use--> Other Host --defined in --> Host defines(template or other config file)
:check_command --command_name --> command_line --OF--> Command defines
The orignal Service does not use others but have many attributes which canbe modified by its's son.
define service{
use generic-service
name passive_service
active_checks_enabled 0
passive_checks_enabled 1 # We want only passive checking
flap_detection_enabled 0
register 0 # This is a template, not a real service
is_volatile 0
check_period 24x7
max_check_attempts 1
normal_check_interval 5
retry_check_interval 1
check_freshness 1
contact_groups admins
check_command check_dummy!0
notification_interval 120
notification_period 24x7
notification_options w,u,c,r
stalking_options w,c,u
}