Page 1 of 1

alert notification setting.

Posted: Wed Nov 04, 2015 9:31 am
by amit.ahuja
I have my notification options setting at w,c,r. Alerts are sending out every 15 mins when services go to critical or recovery state. I want notification to send out only once for critical or warning and another one when it only goes to recovery state instead of every 15 mins. How do I do that?


max_check_attempts 3
check_interval 15
retry_interval 1
check_period 24x7
contact_groups support
event_handler notify-service-by-email
notification_interval 15
notification_period 24x7
notification_options w,c,r
notifications_enabled 1
register 1
}

Re: alert notification setting.

Posted: Wed Nov 04, 2015 9:48 am
by tmcdonald
Setting the notification interval to 0 will cause just one to be sent out for a given state.

https://assets.nagios.com/downloads/nag ... ml#service

Re: alert notification setting.

Posted: Wed Nov 04, 2015 10:12 am
by haile711
Hey tmcdonald,

So if we set this to "0" it will only notify if there is a change in the state of the service?

Re: alert notification setting.

Posted: Wed Nov 04, 2015 1:21 pm
by hsmith
That's the intended functionality, yes.
This directive is used to define the number of "time units" to wait before re-notifying a contact that this service is still in a non-OK state. Unless you've changed the interval_length directive from the default value of 60, this number will mean minutes. If you set this value to 0, Nagios will not re-notify contacts about problems for this service - only one problem notification will be sent out.
https://assets.nagios.com/downloads/nag ... tions.html

Re: alert notification setting.

Posted: Thu Nov 05, 2015 10:42 am
by haile711
Thanks you for your respond hsmith. I will continue testing this and let you know.

Re: alert notification setting.

Posted: Thu Nov 05, 2015 10:46 am
by hsmith
Sounds good. Let us know what you come up with.

Thanks!