Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 6A0DFB5DE0E for ; Wed, 2 Nov 2011 01:03:24 -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 11593-02 for ; Wed, 2 Nov 2011 04:03:18 +0000 (UTC) X-Greylist: delayed 00:08:15.586738 by SQLgrey-1.8.0-rc2 Received: from mail-vx0-f174.google.com (mail-vx0-f174.google.com [209.85.220.174]) by mail.postgresql.org (Postfix) with ESMTP id B0BB0B5DE06 for ; Wed, 2 Nov 2011 01:03:17 -0300 (ADT) Received: by vcge1 with SMTP id e1so6335734vcg.19 for ; Tue, 01 Nov 2011 21:03:17 -0700 (PDT) Received: by 10.52.98.129 with SMTP id ei1mr2679782vdb.50.1320206099340; Tue, 01 Nov 2011 20:54:59 -0700 (PDT) Received: from [192.168.0.105] (125-237-67-169.jetstream.xtra.co.nz. [125.237.67.169]) by mx.google.com with ESMTPS id ib2sm1600352vdb.1.2011.11.01.20.54.56 (version=SSLv3 cipher=OTHER); Tue, 01 Nov 2011 20:54:58 -0700 (PDT) Subject: Re: BUG #6275: Horrible performance regression From: Finlay Thompson To: Mark Kirkwood Cc: pgsql-bugs@postgresql.org In-Reply-To: <4EAF74F6.6020200@catalyst.net.nz> References: <201110280242.p9S2gdRI054867@wwwmaster.postgresql.org> <4EAF74F6.6020200@catalyst.net.nz> Content-Type: text/plain; charset="UTF-8" Date: Wed, 02 Nov 2011 16:54:53 +1300 Message-ID: <1320206093.10204.76.camel@frank.dragonfly.co.nz> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201111/17 X-Sequence-Number: 31612 Hi Mark Thanks for your suggestions (and Robert and Guillaume). I will try the overcommit_memory=2 idea out in a couple of weeks. At the moment I am running everything on 8.4.8, which is working great, and have pressing deadlines looming (next Wednesday). I'll let you know when I do. I want to find a test case that exhibits a real postgresql bug, or informs me as to what I have done wrong. Regards, Finaly On Tue, 2011-11-01 at 17:26 +1300, Mark Kirkwood wrote: > On 28/10/11 15:42, Finlay Thompson wrote: > > After upgrading the postgresql*-8.4 packages on ubuntu, to version 8.4.9, > > the script suddenly stopped working, and consuming all the ram (16GB) on the > > computer (i7). > > > > > > If there is one query exhausting all ram, then it could be tricky to > catch it in the logs (log duration and friends log the query time on > completion... which might be never). If you have vm.overcommit_memory > set to 2 then you may get the offending statement in the log when the > postgres backend errors out with ENOMEM. > > If you know the approx time at which memory starts filling up then > getting (most of) the query text from pg_stat_activity would enable you > to track down the offending sql in your load script. > > regards > > Mark -- Finlay Thompson www.dragonfly.co.nz Dragonfly, PO Box 27535, Wellington 6141, New Zealand Level 5, 158 Victoria Street, Te Aro, Wellington M: +64 21 426 878 T: +64 4 385 9285