Re: Tricks for more levels than s + s/log with svscan.
"Martin A. Brown" <[email protected]>
| Newsgroups | gmane.comp.djb.syslog |
|---|---|
| Message-ID | <[email protected]> |
Greetings Søren,
: I have a program and its logger which I am running under daemontools.
:
: Now, I need a 3rd program to parse the log before sending it to the
: log-rotate mechanism, so I would have something like:
:
: program1
: `- logger1
: `- logger2
:
: Is this possible with daemontools somehow? I tried putting a s/log/log
: but after reading the documentation, obviosly that wasnt the way to go.
: I would like to keep the logic that if one of my programs dies, then it
: should not affect the others (as it is with program + logger).
As Charles Cazabon has indicated, you can use a processor to perform more
manipulations of the log. Here's a simple example:
run file:
exec multilog t !./processor ./data/
data/processor file:
exec sed -e 's| cat | dog |g'
Just make sure that your processor is as bulletproof as possible. You
don't want it failing.
-Martin
--
Martin A. Brown --- SecurePipe, Inc. --- [email protected]