I have logmon looking for my netbackup errors from 2-800. By starting at 2 I have excluded 0 and 1 but I also need to exclude 150 and 157. Wondering if anyone might have a way to do this?
You can use exclude rules in the logmon configuration to exclude log lines that would normally match your watcher rules.
There are a couple of issues with your regex though.
Matching ranges of numbers in a regex can be a little tricky. The exclude rules make it much easier though. Here is one possible approach...
If the range of possible exit status values only goes up to 800, then the watcher rule becomes much simpler (but still requires the exclude rules):
I would definitely recommend testing whatever regex you decide to use to make sure it does exactly what you want. NMS uses PCRE, so testing is fairly easy because you can code a test in a Perl script. (Well, that is easy only if you know Perl, I suppose.) There is also a regex tester available in the NAS GUI, which I think you could use to test this.
Very cool .. I have been reading regex-info but as you can see I am new at this...
Also.. D'oh!.. I totally forgot about excludes... just one of those days I guess.
Thanks for the help.
Retrieving data ...