Downtime Notifications

Hi

Is it possible to schedule a downtime that will not send a notification when downtime starts?

So for example, I want to set a downtime tomorrow on a host from 5am until 7am. Currently (for me at least) Icinga will send out a set of notification emails at 5am that each service on that host has Downtime starting. Then at 7am another set of notification emails are sent to state the Downtime has ended.

So my question is, are we able to suppress those email alerts? Ideally we would like no emails to be triggered for this host throughout the downtime.

Thank you.

You can configure which type of notification you want on the Notification or User object. The default is to send everything, so just define an array of types which you really want to be notified about.

1 Like

Here is an example from my environment: scenario where we only send CRITICAL alerts (no recoveries, acknowledgement, warnings, or downtime alerts):

Director version:

Config version (notice STATES and TYPES):

apply Notification "NOTIFY_rabbitmq_rule" to Service {
    import "Notify_Template_RMQ"

    times.begin = 5m
    assign where !("REDACTED1" in service.groups) || !("REDACTED2" in service.groups) || !("REDACTED3" in service.groups) || !("REDACTED4" in service.groups)
    states = [ Critical ]
    types = [ Problem ]
    vars.agent = "icinga"
    vars.host = "$host.name$"
    vars.output = "\"*** Icinga ***Notification Type:$notification.type$ Host: $host.name$ ($host.address$) Service: $service.display_name$ State: $service.state$ Info: $service.output$ Date/Time: $icinga.long_date_time$\""
    vars.service = "$service.display_name$"
    vars.status = "$service.state$"
    vars.time = "$icinga.long_date_time$"
    vars.zone = "$service.zone$"
}

Icinga2 docs:
https://icinga.com/docs/icinga-2/latest/doc/03-monitoring-basics/#notifications

1 Like

Of course. I need to remove the downtime* from my config:

Blockquote
Service Types
types = [ Problem, Acknowledgement, Recovery, Custom,
FlappingStart, FlappingEnd,
DowntimeStart, DowntimeEnd, DowntimeRemoved ]

Thank you for the speedy responses, much appreciated.

:grinning: :+1:

1 Like