Xymon Mailing List Archive search

client-local.cfg and hobbit-clients.cfg and Wildcard

2 messages in this thread

list James Wade · Tue, 28 Nov 2006 17:07:30 -0600 ·
I want to monitor several logfiles in a directory.

 
Can I use wildcards in the client-local.cfg and hobbit-clients.cfg file for
the client?

 
Would this work?

client-local.cfg example:

log: /logs/server1/SystemOut.log*:10240

 
and this?

 
LOG  logs/server1/SystemOut.log* %Error|Warning COLOR=YELLOW

 
If not, can you suggest another method?

 
Thanks.James
list Henrik Størner · Wed, 29 Nov 2006 07:50:14 +0100 ·
On Tue, Nov 28, 2006 at 05:07:30PM -0600, James Wade wrote:
Would this work?

client-local.cfg example:
log: /logs/server1/SystemOut.log*:10240
No, you need to run a command to generate the filenames on the client.
So something like this would do it:
   log:`ls -1d /logs/server1/SystemOut.log*`:10240
and this?

LOG  logs/server1/SystemOut.log* %Error|Warning COLOR=YELLOW
You need to flag the log filename as a regex, so:
  LOG  %/logs/server1/SystemOut.log.* %Error|Warning COLOR=YELLOW

This is documented in the man-page for the config files, btw ...


Regards,
Henrik