I have been dealing with this problem for a few days now and perhaps I
will be able to solicit some advice or help. Here is the issue. I have
an rsyslog relay writing to a remote database server and caching to
disk. The write to the database uses a MySQL stored procedure that can
write about 4000 records per second. The rsyslog.conf parts are set up
like so:
$ModLoad immark
$ModLoadd imudp
$UDPServerAddress 172.16.12.138
$UDPServerRun 514
$ModLoad imtcp
$ModLoad imuxsock
$ModLoad imklog
$ModLoad ommysql.so
$template template1,"CALL
SAT2_RSYSLOG_EVENT_INSERT('%timestamp:::date-mysql%',
'%timegenerated:::date-mysql%', '%syslogfacility%', '%syslogpriority%',
'%hostname%', '%syslogtag%', '%msg%')", sql
$WorkDirectory /rsyslog/work
$ActionQueueType LinkedList # use asynchronous processing
$ActionQueueFileName dbq # set file name, also enables disk mode
$ActionResumeRetryCount -1 # infinite retries on insert failure
*.* >172.16.2.238,rsyslog,syslogwriter,topsecret;template1
If I turn off the database, in this case I turned it off for almost a
day, it backlogs nearly a 1 GB worth of information. The problem is
that it takes nearly 6 hours to catch back up from this. While catching
up, it only uses about 1% of the proc. Bandwidth is not an issue as the
fibre link is only about 50% saturated. Is there a way to force
rsyslogd to consume more of the proc and move faster. I have placed a
-20 nice value on the process in hopes that would help but it really has
not. Is there a way to force rsyslogd to use a pool of MySQL
connections or intiate a new connection each time a record is written?
Daniel M. Anson
Linux Systems Engineer
Rackspace Managed Hosting
danson@rackspace.com
Confidentiality Notice: This e-mail message (including any attached or
embedded documents) is intended for the exclusive and confidential use of the
individual or entity to which this message is addressed, and unless otherwise
expressly indicated, is confidential and privileged information of Rackspace.
Any dissemination, distribution or copying of the enclosed material is prohibited.
If you receive this transmission in error, please notify us immediately by e-mail
at abuse@rackspace.com, and delete the original message.
Your cooperation is appreciated.
_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com
will be able to solicit some advice or help. Here is the issue. I have
an rsyslog relay writing to a remote database server and caching to
disk. The write to the database uses a MySQL stored procedure that can
write about 4000 records per second. The rsyslog.conf parts are set up
like so:
$ModLoad immark
$ModLoadd imudp
$UDPServerAddress 172.16.12.138
$UDPServerRun 514
$ModLoad imtcp
$ModLoad imuxsock
$ModLoad imklog
$ModLoad ommysql.so
$template template1,"CALL
SAT2_RSYSLOG_EVENT_INSERT('%timestamp:::date-mysql%',
'%timegenerated:::date-mysql%', '%syslogfacility%', '%syslogpriority%',
'%hostname%', '%syslogtag%', '%msg%')", sql
$WorkDirectory /rsyslog/work
$ActionQueueType LinkedList # use asynchronous processing
$ActionQueueFileName dbq # set file name, also enables disk mode
$ActionResumeRetryCount -1 # infinite retries on insert failure
*.* >172.16.2.238,rsyslog,syslogwriter,topsecret;template1
If I turn off the database, in this case I turned it off for almost a
day, it backlogs nearly a 1 GB worth of information. The problem is
that it takes nearly 6 hours to catch back up from this. While catching
up, it only uses about 1% of the proc. Bandwidth is not an issue as the
fibre link is only about 50% saturated. Is there a way to force
rsyslogd to consume more of the proc and move faster. I have placed a
-20 nice value on the process in hopes that would help but it really has
not. Is there a way to force rsyslogd to use a pool of MySQL
connections or intiate a new connection each time a record is written?
Daniel M. Anson
Linux Systems Engineer
Rackspace Managed Hosting
danson@rackspace.com
Confidentiality Notice: This e-mail message (including any attached or
embedded documents) is intended for the exclusive and confidential use of the
individual or entity to which this message is addressed, and unless otherwise
expressly indicated, is confidential and privileged information of Rackspace.
Any dissemination, distribution or copying of the enclosed material is prohibited.
If you receive this transmission in error, please notify us immediately by e-mail
at abuse@rackspace.com, and delete the original message.
Your cooperation is appreciated.
_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com