Another question/problem with notifications + groups

Hey there.

So, if you saw my last thread, we are currently in the process of migrating from Icinga1 to Icinga2. Most has been done and Icinga2 works for the most part how it should. I do have a few problems and I am not sure if I misunderstand something or if I am doing something wrong.

First question:
Currently, every host and service checks whether it is down, warning, up or whatever. If it changes states it sends a mail or a SMS for the more important stuff. However, can I somehow stop the services from sending notifications if the host itself is down? I would assume I have to add another condition to the notification apply rule where it checks if the host on which the services are located itself is up and running to even send a notification.
If that is right: What would the command be? And if that is wrong, can this even be done and if it can where would that be? We are currently only checking
host.enable_notifications is true
AND
service.vars.[notfications] contains [notifcation group]

Second question:
We currently have 2 apply rules notifcations. One is for Mail, one for SMS. I wanted to add one for important stuff that has to send a notifcation every minute. I basically copied an existing one and only changed the time from 600 seconds to 60 seconds. I then added this to a service/host that should send it every minute. However, a few days later a completely unrelated host started sending out notifications every minute.
Was that because I didn’t change the group? Because that’s the only thing I could think of. I though It wouldn’t have to make another group with the same people in it for this. It basically only stopped after I changed the interval from 60 seconds to 600 seconds.

Last question:
Wre often get a message that a host is “UP” or “Recovery” but we never get the “DOWN” or “CRITICAL” notification, probably because while it takes a few minutes, it’s never so long to actually send something (or it switches from “Warning” to “Recovery” and the former doesn’t send a SMS, the latter does though). Could we somehow prevent the system from sending out this if a certain state, in this case “DOWN” or “CRITICAL” never happens?

Hii @Soelf,

This might be helpful for your first question. Icinga Dependencies and Implicit Dependencies for Services on Host.

Second question: It’s really hard to just tell you what the problem could be without letting us see your notification apply rule config. So, sharing this here would be quite helpful. But if I can guess, it somehow matches this completely unrelated host in this apply rule.

Third question: When you have configured your notification templates correctly, the following doc snipet should answer your question. Notifications.

Note

Only users who have been notified of a problem before (Warning, Critical, Unknown states for services, Down for hosts) will receive Recovery notifications.

2 Likes

Thank your for the reply! I am currently very busy, so when I finally get some time to read through your links and work on the notifications I may come back to this topic. Could be in a few weeks thoughs