2

I have set up Nagios with chef. It's accurately monitoring things. When a service/host has a problem, I get an email and jabber message, which is exactly how I have configured it.

However when the service/host recovers, I don't get anything. No email or jabber message. The nagios website updates to show that the service/host is OK, I just got no recovery emails. My nagios website lists the notifications it's sent, and they are all problem notifications. There is no record there of any recovery emails.

What can cause this? Is there a different nagios setting for recovery_notification_command?

  • Is the service showing as flapping? – MadHatter Oct 19 '15 at 13:32
  • 1
    Can you post the notification_options of the hosts/templates/contacts? It has to contain r for recovery. – Halfgaar Oct 19 '15 at 13:32
  • @MadHatter No, the service is not flapping. This problem (no recovery notifications) has existed for months and there are no notifcations for any of the dozen+ service problems there has been (slighly noisy nagios) – Rory Oct 19 '15 at 13:36
  • @Halfgaar I think that was it! :) There was no r in the notification_options. I've added that, and will confirm if it works. Please make a proper answer, so that I can upvote/accept. – Rory Oct 19 '15 at 13:41
5

Presumably, you don't have r in the notification_options in your host config, host template, contact config, etc. If nagios doesn't even show recovery notifications in the logs, this is likely it.

BTW, for hosts, one of the options is u. That doesn't mean up as you might expect, it means unreachable, a special state when a host's parent is down. You can opt to choose not to receive those, because if your router is down, you know that everything below it is down too. This is unrelated to you question, but perhaps good to know :)

  • in version 4.4.1 and later, now you have to include the f (flapping) in order to get the email when it is back ok. – majed Aug 23 '18 at 11:35
  • Note to future googlers: notification_options example can be found here. – aggregate1166877 Nov 4 '18 at 21:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.