Q: nagios-2.9 - old bug withhost_name processing?

Thomas Guyot-Sionnest Thomas at zango.com
Fri Oct 19 00:22:15 CEST 2007


> -----Original Message-----
> From: nagios-devel-bounces at lists.sourceforge.net [mailto:nagios-devel-
> bounces at lists.sourceforge.net] On Behalf Of Dmitry Lebkov
> Sent: Wednesday, October 17, 2007 17:45
> To: Nagios Developers List
> Subject: Re: [Nagios-devel] Q: nagios-2.9 - old bug withhost_name
> processing?
> 
> Thomas Guyot-Sionnest пишет:
> >
> > Did you enable use_regexp_matching and/or use_true_regexp_matching in
> > nagios.cfg?
> 
> # cat nagios.cfg | grep 'use.*regex'
> use_regexp_matching=1
> use_true_regexp_matching=1
> 

Then the Regexp matching is the problem. If you don't need that, you can just turn it off. Otherwise the host name must be unique. 

I never used regexp matching in Nagios but with use_true_regexp_matching=1 you should normally be able to achieve what you want by using:

host_name       ^router_$

The ? and $ will match start and end of line respectively so it won't match any other host having the string "router_" as part of it (So when you define router_2 it won't detect a duplicate service).

Thomas


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Nagios-devel mailing list
Nagios-devel at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-devel


More information about the Developers mailing list