Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 07954B5DC00 for ; Tue, 4 Oct 2011 19:37:14 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 48571-05 for ; Tue, 4 Oct 2011 22:37:07 +0000 (UTC) X-Greylist: delayed 00:05:01.719182 by SQLgrey-1.8.0-rc2 Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.186]) by mail.postgresql.org (Postfix) with ESMTP id 67628B5DBF5 for ; Tue, 4 Oct 2011 19:37:07 -0300 (ADT) Received: from [10.177.121.110] (x.152.14.204.web-pass.com [204.14.152.118]) by mrelayeu.kundenserver.de (node=mreu0) with ESMTP (Nemesis) id 0LrG8W-1R1HNg3Fme-013Msk; Wed, 05 Oct 2011 00:32:05 +0200 Message-ID: <4E8B8960.9030903@2ndQuadrant.com> Date: Tue, 04 Oct 2011 15:32:00 -0700 From: Greg Smith User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.16) Gecko/20110818 Icedove/3.0.11 MIME-Version: 1.0 To: pgsql-performance@postgresql.org Subject: Re: : PG9.0 - Checkpoint tuning and pg_stat_bgwriter References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V02:K0:6m5lS63sbfkNm9bBJKjo1nQ8MwJt89SyurWGdfGOJmE xbwm31h6qKi6Suz1KnQZOy2iundaHbKh+vgIWywUN7cM0VED+m fYyHW4rtqTv+zDx56v41b2Xj3Oe83yJeOoops/+Ni1k0B2uJyH eO7CVlizsoBQ7kDXt/aaIHmHGPyZccZhKQZXuNXmrFIp9VVShF gkUVmPa3PWZbUwA2ayc7YDNDjqIozjPGLhkgejzhOZkRuAJWkr T4hUP0RD/chUSdEHrS8V18qIjOJ+DdcFg1dFMpotmyVDuDfo4O vcl9Os85tR3aCyQnzX9Ra3JXFYuWmj8WEqBjhNzm7vjWJ5jlra GDxD3/XfiKNE8ZyIhKdYxzkfdDNp/Oys/PydilNkB X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001 X-Spam-Level: X-Archive-Number: 201110/51 X-Sequence-Number: 45273 On 10/04/2011 03:50 AM, Venkat Balaji wrote: > I had a look at the pg_stat_bgwriter as well. Try saving it like this instead: select now(),* from pg_stat_bgwriter; And collect two data points, space a day or more apart. That gives a lot more information about the rate at which things are actually happening. The long-term totals are less interesting than that. Generally the first round of tuning work here is to increase checkpoint_segments until most checkpoints appear in checkpoints_timed rather than checkpoints_req. After that, increasing checkpoint_timeout might also be useful. -- Greg Smith 2ndQuadrant US greg@2ndQuadrant.com Baltimore, MD PostgreSQL Training, Services, and 24x7 Support www.2ndQuadrant.us