Possible to add host groups to service groups?

Hari Sekhon hpsekhon at googlemail.com
Mon Jul 28 12:50:23 CEST 2008


Sean Carolan wrote:
> Suppose I have configured a host group called "Linux Servers", and I
> also have a service group that contains some basic Linux services for
> monitoring.  Is it possible to simply add the entire host group to
> this service group?
Having just looked the 2.x and 3.x docs it does not appear so. I haven't 
tried it as I don't manually maintain service groups, but consider 
another way of coming at the problem:

If you add a hostgroup to a service, then you can generate the 
servicegroup around it for web interface usage. This way I don't ever 
maintain servicegroups myself, they are automatically generated so that 
I can just use them for grouping views in the nagios web interface.

This may be a reasonable compromise depending on what you are trying to do.

I wrote a python script to generate the servicegroups file, you can find 
it here:

http://www.nagiosexchange.org/cgi-bin/page.cgi?g=Detailed%2F2435.html;d=1

You can still have a manually maintained servicegroup file as well for 
special cases and use it alongside the auto-generated servicegroups by 
sourcing both in nagios.cfg using a couple of cfg_file lines.

-h

-- 
Hari Sekhon


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
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