Hi, product: syslog-ng-1.5.24 platform: linux 2.4.18 (redhat dist) I'm having a problem with postfix logs sent across the network through to syslog-ng which in turn pipes output through to a mysql server using the following directive: destination d_mysql pipe("/tmp/mysql.pipe" template("INSERT INTO syslogs (host, facilit etc etc... The output from postfix has the 'to' and 'from' address dropped: [snip] postfix/smtp[30704]: 157A6703B8: to=, relay=mail.domain.com.... [end snip] It should look like this: [snip] postfix/smtp[30704]: 157A6703B8: to=<user@domain.com>, relay=mail.domain.com.... [end snip] I'm guessing it's something to do with the '<' & '>' characters. I'll have to go through the source to see where it's going wrong, but was hoping that someone else out there had any similar sorts of problems and advice on how to fix. Thanks Ken ------------------------------------------------------------- Ken Blinco Bridge Point Communications Tel: +61 7 3839 0999 497 Adelaide Street Mobile: 0407 275 766 Brisbane QLD 4000, Australia Fax: +61 7 3839 0888 This email and any attachments are subject to copyright. They may also contain confidential information. This email and any attachments may not be distributed, reproduced, copied, stored or transmitted in any form or by any means, without the prior written consent of Bridge Point Communications Pty Ltd ABN 29 083 424 668. Any personal information in this email must be handled in accordance with the Privacy Act 1988 (Cth). Emails may be interfered with, may contain computer viruses or other defects and may not be successfully replicated on other systems. Bridge Point Communications Pty Ltd gives no warranties in relation to these matters. If you have any doubts about the authenticity of an email purportedly sent by us, please contact Bridge Point Communications Pty Ltd immediately.
On Fri, Jan 10, 2003 at 04:05:53PM +1000, Ken Blinco wrote:
Hi,
product: syslog-ng-1.5.24 platform: linux 2.4.18 (redhat dist)
I'm having a problem with postfix logs sent across the network through to syslog-ng which in turn pipes output through to a mysql server using the following directive: destination d_mysql pipe("/tmp/mysql.pipe" template("INSERT INTO syslogs (host, facilit etc etc...
The output from postfix has the 'to' and 'from' address dropped: [snip] postfix/smtp[30704]: 157A6703B8: to=, relay=mail.domain.com.... [end snip]
It should look like this: [snip] postfix/smtp[30704]: 157A6703B8: to=<user@domain.com>, relay=mail.domain.com.... [end snip]
I'm guessing it's something to do with the '<' & '>' characters.
I'll have to go through the source to see where it's going wrong, but was hoping that someone else out there had any similar sorts of problems and advice on how to fix.
the '<' and '>' characters should not cause problems like this as the whole message is read until a '\n' is encountered and '<>' is interpreted at the beginning of the line only. try strace-ing syslog-ng to see what it exactly receives from postfix. (we are logging postfix to syslog-ng without problems) -- Bazsi PGP info: KeyID 9AF8D0A9 Fingerprint CD27 CFB0 802C 0944 9CFD 804E C82C 8EB1
On Fri, 10 Jan 2003 09:26:54 +0100 Balazs Scheidler <bazsi@balabit.hu> wrote:
the '<' and '>' characters should not cause problems like this as the whole message is read until a '\n' is encountered and '<>' is interpreted at the beginning of the line only.
try strace-ing syslog-ng to see what it exactly receives from postfix.
(we are logging postfix to syslog-ng without problems)
-- Bazsi PGP info: KeyID 9AF8D0A9 Fingerprint CD27 CFB0 802C 0944 9CFD 804E C82C 8EB1
_______________________________________________ syslog-ng maillist - syslog-ng@lists.balabit.hu https://lists.balabit.hu/mailman/listinfo/syslog-ng Frequently asked questions at http://www.campin.net/syslog-ng/faq.html
Thanks, I've checked though and found that it was my perl cgi query which was parsing incorrectly. No problem with syslog-ng. Ken ------------------------------------------------------------- Ken Blinco Bridge Point Communications Tel: +61 7 3839 0999 497 Adelaide Street Mobile: 0407 275 766 Brisbane QLD 4000, Australia Fax: +61 7 3839 0888
participants (2)
-
Balazs Scheidler
-
Ken Blinco