[syslog-ng] syslog-ng with sql() command, cpu to 100%

Garry De Toffoli dtgarry at hotmail.com
Wed Oct 7 11:29:53 CEST 2009

I have tried to run syslog-ng in this way:

root at syslog-srv904:/opt/syslog-ng/sbin# ./syslog-ng -f /opt/syslog-ng/etc/syslog-ng.conf

without any option of debug;

on syslog-ng.conf there is:
destination d_mysql {
        host("") username("syslogadmin") password("syslogadmin")
        columns("host", "facility", "priority", "level", "tag", "datetime", "program", "msg")
        values("$HOST", "$FACILITY", "$PRIORITY", "$LEVEL", "$TAG", "$YEAR-$MONTH-$DAY $HOUR:$MIN:$SEC", "$PROGRAM", "$MSG")

MySql is configured to accept the configuration from network, so the host("") username("syslogadmin") password("syslogadmin") is correct;

and the CPU run to 100%

and doesn't write anything to dbase;

but if use this configuration
destination d_mysql {
    program("/usr/bin/mysql -usyslogadmin -psyslogadmin syslog"
    template("INSERT INTO logs (host, facility, priority, level, tag, datetime, program, msg)

run OK;

it seems that the sql() statement go in loop;

where is the error?

Someone can send a configuration that run OK?

Thank you.

Scopri tutti i servizi Windows Live, guarda i video
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.balabit.hu/pipermail/syslog-ng/attachments/20091007/cf0a2bee/attachment.htm 

More information about the syslog-ng mailing list