nagios配置
define host{
host_name Nagios-Client
alias Nagios Client
address 192.168.140.143
check_command check-host-alive
check_interval 5
retry_interval 1
max_check_attempts 5
check_period 24x7
process_perf_data 0
retain_nonstatus_information 0
contact_groups sagroup
notification_interval 30
notification_period 24x7
notification_options d,u,r
}
define service {
host_name Nagios-Server #hosts.cfg 定义的主机名称
service_description check-host-alive #服务描述
check_period 24x7 #检测的时间段
max_check_attempts 4 #最大检测次数
normal_check_interval 3
retry_check_interval 2
contact_groups sagroup #发生故障通知的联系人组
notification_interval 10
notification_period 24x7 #通知的时间段
notification_options w,u,c,r
check_command check-host-alive
}
请问有必要写这么多么? 还有为什么是不是host里写了还要在service里写啊,好像是如果要对一个主机监控两个服务的时候只需要在host里写一个就行了,别的要在service里写就行了,还有就是报警的什么情况是u 什么情况下是c 什么情况下是r啊。