PCRE Assistance

Ryan Novosielski novosirj at umdnj.edu
Fri Mar 26 21:17:48 CET 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I'm feeling rather dopey at not being able to figure this out, but bear
with me.

I'm trying to define a regex that will match, among other things, a line
that begins with: netmon- and any number of characters that follow it,
and then ends with my domain name. The two I need it to match right now
are: "netmon-int.umdnj.edu" and "netmon-ext.umdnj.edu" but there may be
others going forward.

Here is my example:

%(bbdisplay|xymon|katahdin|^netmon-*).umdnj.edu

I was suspicious of the ^, so I tried removing it -- no change. So far
I've tried this list of things:

%(bbdisplay|xymon|katahdin|netmon-*).umdnj.edu
%(bbdisplay|xymon|katahdin|^netmon\-*).umdnj.edu
%(bbdisplay|xymon|katahdin|netmon\-*).umdnj.edu

...maybe one or two others. When I try either of the two hostnames I'm
trying to match with pcretest, I get "No match". Can anyone point me in
the right direction? It's surely something simple.

- --
 ---- _  _ _  _ ___  _  _  _
 |Y#| |  | |\/| |  \ |\ |  | |Ryan Novosielski - Systems Programmer II
 |$&| |__| |  | |__/ | \| _| |novosirj at umdnj.edu - 973/972.0922 (2-0922)
 \__/ Univ. of Med. and Dent.|IST/CST - NJMS Medical Science Bldg - C630
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkutFmsACgkQmb+gadEcsb5ljQCfeHH215LC1dLo3guwlJkPzp4H
6MIAnRILcRuLfvoAsNY5/5uBLNM+QkEH
=eMzo
-----END PGP SIGNATURE-----


More information about the Xymon mailing list