X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 232FE3A6F4F for ; Mon, 20 Dec 2004 14:08:00 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 98261-01 for ; Mon, 20 Dec 2004 14:07:50 +0000 (GMT) Received: from mail1.panix.com (mail1.panix.com [166.84.1.72]) by svr1.postgresql.org (Postfix) with ESMTP id BE7103A6F47 for ; Mon, 20 Dec 2004 14:07:52 +0000 (GMT) Received: from panix2.panix.com (panix2.panix.com [166.84.1.2]) by mail1.panix.com (Postfix) with ESMTP id C5A4E595A6; Mon, 20 Dec 2004 09:07:51 -0500 (EST) Received: (from adler@localhost) by panix2.panix.com (8.11.6p3/8.8.8/PanixN1.1) id iBKE7pH18640; Mon, 20 Dec 2004 09:07:51 -0500 (EST) Date: Mon, 20 Dec 2004 09:07:51 -0500 From: Michael Adler To: Theo Galanakis Cc: pgsql-performance@postgresql.org Subject: Re: PG Logging is Slow Message-ID: <20041220140751.GA20943@pobox.com> References: <16C0CF355FA04944A69E5A4F5299D30B110EAA@ganesh.au.lpint.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <16C0CF355FA04944A69E5A4F5299D30B110EAA@ganesh.au.lpint.net> User-Agent: Mutt/1.4.2.1i X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests= X-Spam-Level: X-Archive-Number: 200412/244 X-Sequence-Number: 9619 On Mon, Dec 20, 2004 at 03:17:11PM +1100, Theo Galanakis wrote: > Under postgres 7.3 logging is incredibly slow! > > I have applied the following settings: > > syslog = 2 > syslog_facility = 'LOCAL0' > syslog_ident = 'postgres' > > log_connections = true > log_duration = true > log_pid = true > log_statement = true > log_timestamp = true > > This severely impacted the performance of our production system, a search > page which took 1-3 seconds now takes over 30, is this normal? > > I need to get some performance indicators from our production db, however I > cant turn on logging with such performance degradation. I've experienced this problem many times due to hanging dns lookups. /etc/resolv.conf may point to a nonexistent nameserver. Comment it out and restart syslogd. Or use a syslog implementation that allows you to disable dns lookups. Or just give the nameserver a kick. -Mike Adler