Page 1 of 1

Re: [Nagios-devel] Q: nagios-2.9 - old bug withhost_name processing?

Posted: Thu Oct 18, 2007 2:23 pm
by Guest
> -----Original Message-----
> From: [email protected] [mailto:nagios-devel-
> [email protected]] 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?
>=20
> Thomas Guyot-Sionnest =D0=C9=DB=C5=D4:
> >
> > Did you enable use_regexp_matching and/or use_true_regexp_matching =
in
> > nagios.cfg?
>=20
> # cat nagios.cfg | grep 'use.*regex'
> use_regexp_matching=3D1
> use_true_regexp_matching=3D1
>=20

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.=20

I never used regexp matching in Nagios but with =
use_true_regexp_matching=3D1 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 post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]