Re: [ADMIN] syslog slowing the database? - Mailing list pgsql-performance

From Magnus Naeslund(t)
Subject Re: [ADMIN] syslog slowing the database?
Date
Msg-id 404E6A1E.8040804@fbab.net
Whole thread Raw
In response to Re: [ADMIN] syslog slowing the database?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-performance
Tom Lane wrote:
> Greg Spiegelberg <gspiegelberg@cranel.com> writes:
>
>>I turned syslog back on and the restore slowed down again.  Turned
>>it off and it sped right back up.
>
>
> We have heard reports before of syslog being quite slow.  What platform
> are you on exactly?  Does Richard's suggestion of turning off syslog's
> fsync help?
>

Another tip is to use a better (well atleast more optimized) syslog
implementation, like metalog. It optimizes log writes to a blocksize
that is better for disk throughput.
You can also use "per line" mode with those if you want, i think.

I use another logger that is called multilog (see at http://cr.yp.to),
that's a pipe logger thing, like one per postmaster.
It also gives very exact timestamps to every line, has built in log
rotation and works nice with all programs i use it for.

One thing is for sure, if you log much, standard syslog (atleast on
linux) sucks big time.
I gained back approx 30% CPU on a mailserver over here by changing to
another logger.

Cheers
Magnus




pgsql-performance by date:

Previous
From: Mike Bridge
Date:
Subject: High CPU with 7.4.1 after running for about 2 weeks
Next
From: Tom Lane
Date:
Subject: Re: High CPU with 7.4.1 after running for about 2 weeks