Selective email/paging notifications
Subhendu Ghosh
sghosh at sghosh.org
Wed Nov 2 05:05:30 CET 2005
On Tue, 1 Nov 2005, Scot Jenkins wrote:
> I'm running Nagios 1.2 on FreeBSD 4.11 and Nagios 1.3 on Debian
> stable. I've read over the documentation on notifications but didn't
> find an answer to my question.
>
> Given a specific service on a host, I'd like to only receive an email
> for warning and/or unknown status, yet receive email and pages for
> critical and recovery events.
>
> In my services.cfg, I've tried listing the service twice, once with:
>
> ...
> define service {
> host_name gw
> service_description CPU
> contact_groups emails
> notification_options w,u
> ...
> }
>
> define service {
> host_name gw
> service_description CPU
> contact_groups emails,pagers
> notification_options c,r
> ...
> }
>
>
> The Nagios preflight check (nagios -v nagios.cfg) errors with:
>
> Error: Service 'CPU' on host 'gw' has already been defined.
>
> In addition to this it would also be nice to be able to receive
> notifications during the day for a given service yet disable it at
> other times. For example, if the CPU is high during the day email and
> page me, but I don't want to be paged in the middle of the night. I
> know I could use different notification periods but how can I do that
> for the same service on a give host?
>
> Does anyone have suggestions/examples on how to implement either of
> these things?
>
> Thanks,
> Scot
>
Define a single service will notifications for all events.
Define different contacts that receive different notifications/coverage.
eg: contact_groups - admins
members of admin: email-w, email-day, pager-day, pager, email
email-day (only receives notifications during working-hours)
pager-day (only receives notifications during working-hours)
email-w: only receives w
email: only receives c,r
page: only receives c,r
--
-sg
-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
More information about the Users
mailing list