Services are dependent on the host they run on?

Roberto Nunnari roberto.nunnari at supsi.ch
Wed Jun 1 16:41:08 CEST 2011


Roberto Nunnari wrote:
> Hi Gerald.
> 
> 
> Ortner, Gerald wrote:
>> What host/service check interval/max check attempts do you use?
>> Maybe the host check interval is much longer than the service check interval.
>> If the services become hard state critical before the host check does, the service notifications will be sent, as Nagios isn't aware of the host problem.
>> I don't know how Nagios behaves if the host is only in soft state?
> 
> I believe that may be the problem.
> The service and host check interval were all 1 minute.
> Maybe, if the checks on the services happen to fail before the checks on 
> the host, then notification for all failed services will be sent anyways.
> 
> This assumes that nagios doesn't care about service dependency on the 
> host running the service when the host is in soft state critical, but 
> only when the host is in hard state critical.
> 
> I modified host/service check interval as follow:
> define host {
> ...
>          max_check_attempts              3
>          normal_check_interval           1
>          retry_check_interval            1
> ...
> }
> define service {
> ...
>          max_check_attempts              3
>          normal_check_interval           3
>          retry_check_interval            2
> ...
> }
> 
> The above should always give host checks for the host to reach a hard 
> state critical before the services in case the host goes down.
> 
> I've already run an easy test and the result confirmed what stated 
> above, but I'll run some more tests as soon as possible, maybe already 
> tomorrow, and report the results here.

Hi all.
I can confirm that now I can no longer reproduce that undesired 
behavior. So it seems that it was a misconfiguration of the host/service 
check interval/max check attempts.
I would be very helpful though, if 'nagios -v' would signal that, at 
least as a warning. If I'll ever get round to, I'd be pleased to 
contribute a patch for that.

Thank you very much and best regards.
Roberto Nunnari


> 
> Thank you to all.
> Robi
> 
>> hth
>> gerald
>>
>>> -----Ursprüngliche Nachricht-----
>>> Von: Roberto Nunnari [mailto:roberto.nunnari at supsi.ch]
>>> Gesendet: Freitag, 27. Mai 2011 09:01
>>> An: Nagios Users List
>>> Betreff: Re: [Nagios-users] Services are dependent on the host they run on?
>>>
>>> Hi Mark.
>>>
>>>
>>> Frost, Mark {PBC} wrote:
>>>> Maybe I'm missing something but I thought that suppressing notifications
>>> for services on the same host when the host goes down is the default
>>> behavior.  It's only when you have to suppress notifications from different
>>> hosts that you need host/service dependencies.
>>>
>>> That's exactly what I was expecting, but it doesn't seem to work that way.. at
>>> least not for me.
>>>
>>> Yesterday for instance, a host went down because of a hd controller failure,
>>> and I received 22 sms..
>>>
>>> Robi
>>>
>>>
>>>> Mark
>>>>
>>>> -----Original Message-----
>>>> From: Assaf Flatto [mailto:nagios at flatto.net]
>>>> Sent: Thursday, May 26, 2011 1:39 PM
>>>> To: Nagios Users List
>>>> Subject: Re: [Nagios-users] Services are dependent on the host they run
>>> on?
>>>> Martin Hugo wrote:
>>>>> Hi Robi,
>>>>>
>>>>> I have never done it but I know you can make hosts/services children that
>>> will not report if the parent is down.
>>>>> Hope this puts you on the right track.
>>>>>
>>>>> Marty
>>>>>
>>>>> -----Original Message-----
>>>>> From: Roberto Nunnari [mailto:roberto.nunnari at supsi.ch]
>>>>> Sent: Thursday, May 26, 2011 12:47 PM
>>>>> To: nagios-users at lists.sourceforge.net
>>>>> Subject: [Nagios-users] Services are dependent on the host they run on?
>>>>>
>>>>> Hi all.
>>>>>
>>>>> Some time ago, I've installed and configured nagios to monitor our IT
>>>>> infrastructure.
>>>>>
>>>>> It works very well and we're happy with it.
>>>>>
>>>>> There's still one problem though:
>>>>> When a host goes down, nagios sends notifications not only for host
>>>>> down, but also for all services running on that host. When a host
>>>>> goes down, I would like nagios to only send notifications about the
>>>>> host down, and not for all the services running on that host.
>>>>>
>>>>> How can I achive that?
>>>>> May it be a configuration error from my side? I thought that to
>>>>> nagios, services would be dependent from the host running them..
>>>>>
>>>>> Any hint/advice/guidance is very welcome.
>>>>>
>>>>> Thank you and best regards.
>>>>>
>>>>> Robi
>>>>>
>>>> check out service dependencies
>>>>
>>>> http://nagios.sourceforge.net/docs/3_0/dependencies.html


------------------------------------------------------------------------------
Simplify data backup and recovery for your virtual environment with vRanger. 
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Data protection magic?
Nope - It's vRanger. Get your free trial download today. 
http://p.sf.net/sfu/quest-sfdev2dev
_______________________________________________
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