service dependencies with host group

Assaf Flatto nagios at flatto.net
Fri Apr 30 17:48:03 CEST 2010


Flyinvap wrote:
> Hi,
>
> Is it possible do use service dependencies on with hostgroup ? All
> services are applied to hostgroup :
>
> define service {
>         use                     generic
>         name                    service1
>         description             service1
>         hostgroup               server
>         check_command           check1
> }
>
> define service {
>         use                     generic
>         name                    service2
>         description             service2
>         hostgroup               server
>         check_command           check2
> }
>
> Is it possible that nagios doesn't send notification for service1 if
> service2 is not OK ? I try to declare service dependency like :
>
> define servicedependency {
>        dependent_hostgroup_name        server
>        dependent_service_description   service1
>        hostgroup_name                  server
>        service_description             service2
>        inherits_parent                 0
>        execution_failure_criteria      n
>        notification_failure_criteria   w,u,c
> }
>
> It take a long, long, long time to verify config
>
> $ nagios3 -v nagios.cfg
> [...]
> Checking for circular paths between hosts...
> Checking for circular host and service dependencies...
> ^C
>
> I'm afraid I have declared dependencies from each host to all other ...
>
> Regards.
>
>   
Basically what you defined is service 2 is dependent on service1 on ALL 
hosts in the hostgroup server.

and i assume you have a large number of hosts in the group so nagios is 
building a long list of dependencies .
Take a look here - and it might help you sort this one out

http://nagios.sourceforge.net/docs/3_0/objecttricks.html

-- 
Never,Ever Cut A Deal With a Dragon 


I am doing a Charity Bike ride On the 27 of June for the
Capital to Coast Charity. Please help by Donating
http://www.justgiving.com/Lovefilm-capital-to-coast



------------------------------------------------------------------------------
_______________________________________________
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