Why is it that syslog-ng places the program name in the message string? As in: [CODE] source shell { unix-dgram("/dev/log"); internal(); udp(); }; destination deadman { file("/var/log/deadman" template ("PROGRAM:$PROGRAM <MESSAGE:$MSG> LEVEL:$LEVEL PRIORITY:$PRIORITY FACILITY:$FACILITY\n") template_escape(no) ); }; log { source(shell); destination(deadman); }; [/CODE] [OUTPUT] PROGRAM:roberto <MESSAGE:roberto: this is a test> LEVEL:notice PRIORITY:notice FACILITY:user [/OUTPUT] I'd like to see just the words "this is a test" in the $MSG variable. I am using syslog-ng version 1.5.24, on OpenBSD 3.5. Thanks in advanced.
On Fri, Sep 10, 2004 at 02:10:03PM -0400, Robert.COward@deploymenthealth.osd.mil wrote:
Why is it that syslog-ng places the program name in the message string? As in:
<snip>
I'd like to see just the words "this is a test" in the $MSG variable. I am using syslog-ng version 1.5.24, on OpenBSD 3.5.
I think it's because the program name isn't required and often isn't there. If it's always chopped then you'll lose valuable information much of the time from the actual message. -- Nate "C(++) is a write-only, high-level assembler language." - Stefan Van Baelen.
Robert.COward@deploymenthealth.osd.mil - Fri, Sep 10, 2004:
I'd like to see just the words "this is a test" in the $MSG variable.
I'd prefer that too, but there is also the $MSGONLY macro. Regards, -- Loïc Minier <lool@dooz.org>
participants (3)
-
Loic Minier
-
Nate Campi
-
Robert.COward@deploymenthealth.osd.mil