Ian Forde wrote:
> Hi all -
> 
> I've noticed that you can have multiple "members" lines in the
> hostgroups.cfg hostgroup entries.  Unfortunately, while rewriting a
> fairly large Nagios configuration to support Distributed monitoring, I
> separated out our services.cfg lines to have multiple "hostgroups" lines
> for a given services.  This quite neatly broke the config, as it seems
> that it only reads the last hostgroups line listed for a given service.
> 
> Any chance of a fix?
> 


I'm not sure if this is a bug or by design. I believe "members" was 
treated specially because those lines tended to grow very, very large. 
Everywhere else the last specified option takes precedence.


define service{
        hostgroups      foo
        hostgroups      bar
}

will assign this service to hostgroup "bar" only.

define service{
        hostgroups      foo,bar
}

will assign this service to hostgroups "foo" and "bar".

Some fairly simple perl/python/php/ruby/manual hackery should work famously.

-- 
Andreas Ericsson                   [EMAIL PROTECTED]
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Nagios-users mailing list
[email protected]
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

Reply via email to