San*_*dra 4 linux ubuntu centos nagios
我所有 linux 主机的联系人是admins
Nagios contact_group
。但是对于这个 Linux 主机,我希望被contact_group
调用者sandradebug
也得到通知。
问题是,当我添加contact_groups sandradebug
它时,它仍然只是admins
收到通知,而不是sandradebug
.
题
我怎样才能包括sandradebug
这个主机,以便通知也会发送到那里?
主机模板
define host {
name linux-host
use generic-host
check_command check-host-alive
notification_interval 4320
notification_options d,u,r
contact_groups admins
register 0
}
Run Code Online (Sandbox Code Playgroud)
主机定义
define host {
use linux-host
host_name example
alias example
address 10.10.10.10
hostgroups default-linux-services
contact_groups sandradebug
}
Run Code Online (Sandbox Code Playgroud)
问题是,当我添加
contact_groups sandradebug
它时,它仍然只是admins
收到通知,而不是sandradebug
.
您是否重新启动了 Nagios?您的上述配置将覆盖模板值,并且只有sandradebug
组会收到这些警报。
我怎样才能包括
sandradebug
这个主机,以便通知也会发送到那里?
对象继承是您正在寻找的:
define host {
use linux-host
host_name example
alias example
address 10.10.10.10
hostgroups default-linux-services
contact_groups +sandradebug
}
Run Code Online (Sandbox Code Playgroud)
使用+
标志,主机定义使用模板中的数据并将其添加sandradebug
到警报中。
归档时间: |
|
查看次数: |
5951 次 |
最近记录: |