hostgroup with no members - Enhancement

Andreas Ericsson ae at op5.se
Tue Nov 2 08:33:53 CET 2010


On 11/01/2010 08:57 PM, Daniel Wittenberg wrote:
> I'd like to be able to create a hostgroup with no members assigned, but
> doesn't appear to work.

Empty hostgroups work just fine. The check that says this is so starts
at line 12516 in xdata/xodtemplate.c as of latest CVS/git. It's been
like that for a while now.

>  The reason being is that I'm generating the
> host configs using a third-party tool, and it puts in that host file
> which hostgroups a host belong to.  This works great, but there has to
> be at least 1 member in the hostgroup for it not to complain.  It would
> be nice if I could just put the hostgroups out there blank and then let
> the host definition completely populate what's in there.  Right now I
> have 1 fake host that is in every group, so I have one host with
> hundreds of service checks that will fail , just rather messy.
> 

So what you *really* want is some way of assigning services to hosts
from within the service. That's an entirely different thing. You could
add "register 0" to the fake host definition. Not sure if that would
work, but it's possible that it does.

> Does that sound reasonable, another way to do this I've missed?
> 

The hopefully-up-and-coming way of handling this is to use service sets,
a feature I've been thinking of for quite some time now. It can be
safely implemented without altering the object structure version, which
is quite nice, and will mean you can assign a set of services to a host
from within the definition of that host. The idea is to, in the long
run, use service sets to create full host types that can be shared among
community members.

Would that satisfy your needs?

-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231

Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
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