Customizing Nagios


#1

I have serveral questions about customizing several different things in Nagios. First of all, I want to build a contact list in the nagios .cfg file with multiple emails and phone numbers to send automatic emails and SMS’s. I treid placing multiple email for the contact list in the nagios.cfg file, but I must’ve had the wrong code. Can anyone tell me the write way to build this list in the nagios.cfg file.

I also want to control how often nagios sends an email when something goes wrong, last night I recieved around 20 emails in 8 hours over the same problem. How can I limit that interval in which nagios sends out both emails, and SMS’s if possible. And lastely, what do I need to configure in order to define and use the servicegroup options in nagios?

Please let me know any tips that can be of any help, thanks.

gxr


#2

You have to create contacts.cfg where you will define all emails and all sms’ separately. Then you define contactgroups.cfg where you will define groups of defined contacts from contacts.cfg. Those contact_groups you can then put for contact personel in host and service definitions.

Don’t define contacts in nagios.cfg. In that file you just point where your configuration files are.

For second question you can define notification interval in host/service definitions.
As for servicegroups, when you define the groups you put the members in this order respectively.
service1,service description1,service2,service description2,etc…

Everything I’ve just explainde is very well described in nagios documentation, which you have to read if you want everything to work properly:
nagios.sourceforge.net/docs/2_0/xodtemplate.html


#3

How does it work, when Nagios sends an SMS to a cell phone. How does it connect to a phone line to send that message? I am kind of confused about the way Nagios sends SMS’s.


#4

You got to have some sort of sms gateway. It doesn’t work from Nagios directly. It’s just an option you may use with Nagios. You need a piece of hardware which will act like a mobile phone and the sms gateway software. Google it and you will find out.


#5

Thanks a lot for that link, that was exactly what I was looking for… I really appreciate your post. :smiley: Cheers!!!

gxr