Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id AFA06B5DC60 for ; Tue, 11 Oct 2011 16:52:47 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 59186-03 for ; Tue, 11 Oct 2011 19:52:40 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0-rc2 Received: from polaris.pinpointresearch.com (cerberus.pinpointresearch.com [66.7.238.130]) by mail.postgresql.org (Postfix) with ESMTP id 1108AB5DBE9 for ; Tue, 11 Oct 2011 16:52:36 -0300 (ADT) Received: from betelgeuse.pinpointresearch.com (betelgeuse.pinpointresearch.com [192.168.1.179]) by polaris.pinpointresearch.com (Postfix) with ESMTP id 9A430E00EC83; Tue, 11 Oct 2011 12:52:35 -0700 (PDT) Message-ID: <4E949E83.20603@pinpointresearch.com> Date: Tue, 11 Oct 2011 12:52:35 -0700 From: Steve Crawford User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.23) Gecko/20110922 Lightning/1.0b2 Thunderbird/3.1.15 MIME-Version: 1.0 To: AA CC: pgsql-admin@postgresql.org Subject: Re: min duration logging References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.404 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RP_MATCHES_RCVD=-0.504 X-Spam-Level: X-Archive-Number: 201110/56 X-Sequence-Number: 38508 On 10/11/2011 11:23 AM, AA wrote: > hey all > trying to find non optimized queries and want to use this logging > feature, however postgresql seems to write every query to log. > > my conf is as follows... > > log_min_duration_statement = 450 > ... What durations are showing in the log? Are lots/all of the queries you run longer than 450ms? > #log_statement = 'all' > I don't know what the config looked like beforehand but did you reload PostgreSQL after changing it? You can check the current running settings with "show all;" Cheers, Steve