Hi,
i guess i have somewhere a problem with the assignment for notifications but i cannot find it.
The general notifications works fine. If i trigger a custom notification the email for hosts and services arrive propperly.
I will copy the director preview output for better understanding.
notification template
template Notification "email-service-notification" {
command = "mail-service-notification"
period = "24x7"
states = [ Critical, OK, Unknown, Warning ]
types = [ Custom, Problem, Recovery ]
user_groups = [ "internal-it" ]
}
The command is imported via kickstart and its the default one.
notification apply
apply Notification "service-email" to Service {
import "email-service-notification"
period = "24x7"
assign where service.enable_notifications && "core-asset" in host.groups
states = [ Critical, OK, Warning ]
types = [ Custom, Problem, Recovery ]
users = [ "christianb" ]
}
In the web ui i can see that these notifications are appied to the service or host
But if the service goes in a critical hard state no notifications are triggered
The icinga2.log does not shows
[2024-10-18 09:29:06 +0200] information/Checkable: Checkable 'vmtask01.domain.de!ICINGA2 Agent' has 2 notification(s). Checking filters for type 'Problem', sends will be logged.
[2024-10-18 09:29:08 +0200] information/ApiListener: Reconnecting to endpoint 'vmtask01.tim.de' via host '192.168.150.52' and port '5665'
[2024-10-18 09:29:08 +0200] information/ConfigObject: Dumping program state to file '/var/lib/icinga2/icinga2.state'
I hope some can help. Thx.