FW: Timeperiods and oncall rotation with UK Public holidays
Parish, Brent
bparish at cognex.com
Tue Apr 27 02:49:40 CEST 2010
I've been wanting to chime in on this topic for some time now, but I've
done so much customization in my Nagios environment that it would be
really hard to post the code. For example, my notify.pl script checks
out user preferences that are stored in a database, which requires the
CGI that allows users to change that info, which requires Active
Directory (so they can only see/modify their own stuff). I also run a
private instant message server (OpenFire) so alerts can pop up as
instant messages if users prefer that.
Although I'm certain there are much better ways to do this out there,
here is what works for me in a nutshell:
* use NDOutils to store Nagios configuration and alerts
* store user contact preferences in a MySQL database
* create a CGI and link into the left hand nav panel to allow users to
change contact preferences
* create a new notify.pl from scratch
- Check if it is business hours or non biz hours (to do: use
Nagios time config files)
- Do a select on the database to see who is responsible for this
alert, given time, day, host, service, level, etc.
- Optionally: send alert to generic group/email if no one is
specifically defined
- Read in user preferences from DB, given host, time of day,
etc.
- Send alert according to preference (email address, instant
message, voice, etc)
* Define the contacts' email addresses (inside contacts.cfg) to be the
username (CN) in Active Directory
* Define all users to get alerts all the time, let the database do the
work of sorting out details
If ever get the time to clean up the code, document it better and
explain the dependencies, I'll be happy to post the code somewhere as an
example of one way to do it.
Hope it helps,
- Brent
-----Original Message-----
Sent: Thursday, April 22, 2010 2:08 PM
To: nagios-users at lists.sourceforge.net
Subject: Re: [Nagios-users] [Nagios-devel] FW: Timeperiods and oncall
rotation with UK Public holidays
> If you can find a way to do this, please let me know! My boss is
wanting
> our Nagios installation to do this very thing, but I have yet to find
a
> way to make this happen.
------------------------------------------------------------------------------
_______________________________________________
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