nope...
 


From: syslog-ng-bounces@lists.balabit.hu [mailto:syslog-ng-bounces@lists.balabit.hu] On Behalf Of Dukes Clayton
Sent: Tuesday, March 07, 2006 5:00 PM
To: Syslog-ng users' and developers' mailing list
Subject: RE: [syslog-ng] Splitting a single source to multiple mysql tables

I think this fixed it, can someone confirm?
 
destination d_mysql { pipe("/var/log/mysql.pipe" template("INSERT INTO logs
 (host, facility, priority, level, datetime, msg)
 VALUES ( '$HOST', '$FACILITY', '$PRIORITY', '$LEVEL', '$YEAR-$MONTH-$DAY $HOUR:$MIN:$SEC','$MSG' );\n")
 INSERT INTO host
 (host)
 VALUES ( '$HOST' ) ON DUPLICATE KEY UPDATE count=count+1;\n")
 INSERT IGNORE INTO facility
 (facility)
 VALUES ( '$FACILITY' );\n")
 template-escape(yes)); };
 
 log { source(net); destination(d_mysql); };
 


From: syslog-ng-bounces@lists.balabit.hu [mailto:syslog-ng-bounces@lists.balabit.hu] On Behalf Of Dukes Clayton
Sent: Tuesday, March 07, 2006 4:43 PM
To: syslog-ng@lists.balabit.hu
Subject: [syslog-ng] Splitting a single source to multiple mysql tables

Hiya,
Here's what I have, why doesn't it work?


destination d_mysql { pipe("/var/log/mysql.pipe" template("INSERT INTO logs
 (host, facility, priority, level, datetime, msg)
 VALUES ( '$HOST', '$FACILITY', '$PRIORITY', '$LEVEL', '$YEAR-$MONTH-$DAY $HOUR:$MIN:$SEC','$MSG' );\n") template-esc

destination d_host { pipe("/var/log/mysql.pipe" template("INSERT INTO host
 (host)
VALUES ( '$HOST' ) ON DUPLICATE KEY UPDATE count=count+1;\n") template-escape(yes)); };
 
destination d_mysql_facility { pipe("/var/log/mysql.pipe" template("INSERT IGNORE INTO facility
 (facility)
VALUES ( '$FACILITY' );\n") template-escape(yes)); };

# This doesn't work
#log { source(net); destination(d_mysql); destination(d_host); destination(d_mysql_facility); };

# This works
 log { source(net); destination(d_mysql); };