Page 1 of 2

Service Dependencies

Posted: Wed Feb 20, 2013 1:56 pm
by samuel
Could you explain how to this more in depth. I need to minimize the number of alerts that are going out. Is there a way to make it so that if a host goes down no service notifications are sent out, just host notifications. But if the host is up allow service alerts to go out? I already read the quote below from "Host/Service Dependencies", but that didn't quite make sense.
jronin wrote:I was able to solve my issue by changing the state notification on the services. As all checks are set to one minute I set ping to alert on warn and the rest of the services to alert on warn/crit. This allowed me to have a single up/down e-mail when the host reboots/shuts down and still notify when one of the services has an issue.
What version of Nagios XI are you using? Nagios XI 2012R1.3
Linux Distribution and version? centos 6.3
32 or 64bit? 32bit
VMware Image or Manual Install of XI? VMware Image
Are there specials configurations on your system, ie; is Gnome installed? Are you using a proxy? Are you using SSL? nonef

Re: Service Dependencies

Posted: Wed Feb 20, 2013 2:15 pm
by sreinhardt
I believe that the best option for what you require, would be parent\child relationships for hosts, and the service checks would need to use dependencies. The below two links give better descriptions and examples than I could, but please post any questions!

Host and Service Depenencies
Network reachability

Re: Service Dependencies

Posted: Wed Feb 20, 2013 2:38 pm
by samuel
Both of those are linked to Network reachability. Can you link the right one for Host and Service Depenencies.
sreinhardt wrote:I believe that the best option for what you require, would be parent\child relationships for hosts, and the service checks would need to use dependencies. The below two links give better descriptions and examples than I could, but please post any questions!

Host and Service Depenencies
Network reachability

Re: Service Dependencies

Posted: Wed Feb 20, 2013 2:40 pm
by samuel
I currently have parent and child relationships defined on all of my hosts.

Re: Service Dependencies

Posted: Wed Feb 20, 2013 2:42 pm
by sreinhardt
My mistake, I posted the wrong link. Try this one http://nagios.sourceforge.net/docs/3_0/ ... ncies.html

Re: Service Dependencies

Posted: Wed Feb 20, 2013 3:19 pm
by samuel
How do you make it so that service checks are dependent on the host? As far as I know nagios can only do host to host or service to service.

And is there any way to do a bulk change so that it works that way for all of the hosts?

Re: Service Dependencies

Posted: Wed Feb 20, 2013 4:01 pm
by samuel
I was wondering if this would work.

Make a ping service.
Assign a host group, that has all the hosts in it, to the ping service.
Start making service dependencies.
Add the host group with all hosts in it.
Add ping service to it.
Add all other services as dependencies.
Make the notification failure criteria w,c,u,p.

Re: Service Dependencies

Posted: Wed Feb 20, 2013 4:06 pm
by scottwilkerson
samuel wrote:How do you make it so that service checks are dependent on the host?
Services are automatically dependent on their own host, this is default behavior in Nagios and nothing needs to be setup.

Re: Service Dependencies

Posted: Wed Feb 20, 2013 4:20 pm
by samuel
So if a host is down no service notifications will be sent out?

Re: Service Dependencies

Posted: Wed Feb 20, 2013 5:00 pm
by lmiltchev
Yes, this is the default behavior.