Nagios Notifications based on Status (Warning - Critical)


Hi All,
Is there a way of sending notifications based on the Status of an object?

What I would like to do is send an email if an alert is a warning or send a SMS if the alert is critical. I know I could set up a service for each status , but is there a way to do this without having to setup tons of services?


Ken :?


Yes. You can define two contacts, one for SMS with these options in the contact definitions:

service_notification_options c,r host_notification_options d,u,r service_notification_commands notify-by-epager host_notification_commands host-notify-by-epager

and the second one for mail with:

service_notification_options w,u,r host_notification_options d,u,r service_notification_commands notify-by-email host_notification_commands host-notify-by-email

Add them to one contactgroup, put that contactgroup as contact to service/host definitions and I think that is it.