define service with multiple contactgroups

Axel Rosenski rosenski at wave-computer.de
Wed Mar 23 13:46:43 CET 2011


Am Mittwoch, 23. Mär. 11, 05:54:47 schrieb Anand, Sakshi:
> Purpose of both the services are essentially the same but they come with
> Nagios installation because they have defined these configurations for
> windows as well as linux users.
> 
> You must use only one of them depending on the OS being used.
 
> > I've recently taken over our Nagios config so am still learning, but we
> > seem to do something similar using two services, they just have the same
> > description.  You can't tell there are two services when looking at the
> > alerts or web pages.
> > 
> > (example syntax below, probably full or errors)

How do you manage service escalations with only one service defined?

When I use two hostgroup, one service and one servicegroup definition for all 
default checks the first notifications goes to the correct group, but 
escalations for this service go to all members of both teams
I want to send escalations only to one team. 

Here's my initial config:

# linux server
define host{
   use                              tpl-host-default
   name                             tpl-host-linux
   contact_groups                   pager-linuxadmin
   hostgroups                       hgrp-linux-server
   register                         0
}

define host{
   use                              tpl-host-linux
   host_name                        10.9.1.121
   alias                            lxdev
   address                          10.9.1.121
}

define service{
   service_description              Swap
   use                              tpl-service-standard
   servicegroups                    sgrp-check-standard
   check_command                    check_nrpe!check_space_swap
   hostgroup_name                   hgrp-linux-server
}

define serviceescalation{
   hostgroup_name                   hgrp-linux-server
   servicegroup_name                sgrp-check-standard
   contact_groups                   +cgrp-nagios-test-escalation-mail
   first_notification               3
   last_notification                0
   notification_interval            10
}

## Windows Server
define serviceescalation{
   hostgroup_name                   hgrp-windows-server
   servicegroup_name                sgrp-check-standard
   contact_groups                   +cgrp-nagios-test-escalation-phone
   first_notification               3
   last_notification                0
   notification_interval            10
}

As mentioned in the first reply of my initial question i did not have a 
contact_group for my service templates and with this the notifications are sent 
to the contact group of the host definition.

But when I inspect the settings in objects.cache all standard services 
escalate to both teams.

define serviceescalation {
   host_name   10.9.1.121
   service_description  Swap
   escalation_options   w,u,c,r
   contact_groups pager-linuxadmin,cgrp-nagios-test-escalation-phone
   }
   
define serviceescalation {
   host_name   10.9.1.121
   service_description  Swap
   escalation_options   w,u,c,r
   contact_groups pager-linuxadmin,cgrp-nagios-test-escalation-mail
   }


What do I have to change that escalations work properly? 
I tried to split the servicegroups definition for both teams, but afaics I need 
to define 2 services for each hostgroup.

-- 
Axel Rosenski
- Administration -
______________________________
Wave Computersysteme GmbH
Philipp-Reis-Str. 1-3 / 9
35440 Linden

Geschäftsführer: Carsten Kellmann
Registergericht Gießen HRB 1823

Tel.: +49 (0)6403 / 9050 8317
Fax: +49 (0)6403 / 9050 5089
mailto:rosenski at wave-computer.de
http://www.wave-computer.de


------------------------------------------------------------------------------
Enable your software for Intel(R) Active Management Technology to meet the
growing manageability and security demands of your customers. Businesses
are taking advantage of Intel(R) vPro (TM) technology - will your software 
be a part of the solution? Download the Intel(R) Manageability Checker 
today! http://p.sf.net/sfu/intel-dev2devmar
_______________________________________________
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