Page 1 of 1

Add sevices to servicegroup

Posted: Thu Apr 25, 2013 8:07 am
by MichaelW
Hi all,

I know how to create a service group and to add services to it manually. What I want to do is to do it more automatically.

I have created a service template called fileage-sevice. After that I have created several services that use this template to monitor the age of certain logfiles.
Now I would like to create a service group that includes all services that use the fileage-service template.

Unfortunately

Code: Select all

define servicegroup{
        servicegroup_name       LogFiles
        alias                   Log File Monitor
        members      hostname,fileage-service
        }
does not work.
Any idea how this can be done?

Regards,

Michael

Re: Add sevices to servicegroup

Posted: Thu Apr 25, 2013 10:21 am
by slansing
This can be done two ways as outlined here:

http://nagios.sourceforge.net/docs/3_0/ ... rvicegroup

You can either define the servicegroups as you have, or add the servicegroup name to each individual service's config file, it should work in either fashion, what is happening once you verify the config files?

Re: Add sevices to servicegroup

Posted: Thu Apr 25, 2013 12:56 pm
by MichaelW
Thank you. I didn't realize I can add a servicegroup to a service. This is exactly what I was looking for.