
Tenho problemas para configurar escalonamentos no nagios. Estou recebendo o seguinte erro:
Error: Could not expand hostgroups and/or hosts specified in host escalation (config file '/usr/local/nagios/etc/objects/escalations.cfg', starting on line 11)
Error processing object config files!
O arquivo escalations.cfg tem a seguinte aparência:
define hostescalation{
host_name *
contact_groups admins
first_notification 1
last_notification 3
notification_interval 30
escalation_period 24x7
escalation_options d,u
}
define hostescalation{
host_name *
contact_groups suppliers
first_notification 4
last_notification 6
notification_interval 60
escalation_period 24x7
escalation_options d,u
}
define serviceescalation{
host_name script.myprojects
service_description HTTP
first_notification 1
last_notification 3
notification_interval 30
contact_groups admins
}
define serviceescalation{
host_name script.myprojects
service_description HTTP
first_notification 4
last_notification 6
notification_interval 60
contact_groups suppliers
}
O que eu quero é obter todos os grupos de hosts e seus membros usando o curinga (*). Isto não está a funcionar. Alguém pode fornecer alguma solução? Estou faltando alguma definição e, em caso afirmativo, onde/como colocar essa definição?
Obrigado!
Responder1
Não está claro se você pode usar curingas nesta definição de objeto. Mas supondo que vocêpode, certifique-se de use_regexp_matching=0
seguir este documento do Nagios:
http://nagios.sourceforge.net/docs/3_0/configmain.html#use_regexp_matching