X-Original-To: pgsql-performance-postgresql.org@postgresql.org Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id E940E9FB2FF for ; Mon, 4 Sep 2006 21:30:47 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 58387-04 for ; Tue, 5 Sep 2006 00:30:43 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey- Received: from stark.xeocode.com (stark.xeocode.com [216.58.44.227]) by postgresql.org (Postfix) with ESMTP id 3697D9FB1C8 for ; Mon, 4 Sep 2006 21:30:43 -0300 (ADT) Received: from localhost ([127.0.0.1] helo=stark.xeocode.com) by stark.xeocode.com with smtp (Exim 3.36 #1 (Debian)) id 1GKOpT-0002EC-00; Mon, 04 Sep 2006 20:30:15 -0400 To: Alvaro Herrera Cc: Gregory Stark , Tom Lane , Matteo Sgalaberni , pgsql-performance@postgresql.org Subject: Re: database bloat, non removovable rows, slow query etc... [RESOLVED] References: <20060901123915.GT2266@sgala.com> <4027.1157121810@sss.pgh.pa.us> <20060901172829.GX2266@sgala.com> <12756.1157132120@sss.pgh.pa.us> <20060902083725.GB2266@sgala.com> <2191.1157206883@sss.pgh.pa.us> <87ejur1drl.fsf@stark.xeocode.com> <20060904224716.GB14107@alvh.no-ip.org> From: Gregory Stark In-Reply-To: <20060904224716.GB14107@alvh.no-ip.org> Date: 04 Sep 2006 20:30:15 -0400 Message-ID: <878xkz17fs.fsf@stark.xeocode.com> Lines: 27 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=1.384 tagged_above=0 required=5 tests=SPF_SOFTFAIL X-Spam-Level: * X-Archive-Number: 200609/26 X-Sequence-Number: 20712 Alvaro Herrera writes: > Gregory Stark wrote: > > Tom Lane writes: > > > > > Matteo Sgalaberni writes: > > > > Good to know this...but why this behaviour? it'is lovely...:) > > > > > > Open transactions are tracked across the whole cluster. This is > > > necessary when vacuuming shared catalogs. In principle we could > > > track per-database xmin values as well, but the distributed overhead > > > that'd be added to *every* GetSnapshotData call is a bit worrisome. > > > > Don't we do that now in CVS (ie, in 8.2)? > > No, we don't. I must be misunderstanding Tom's comment then. What I'm referring to is lazy_vacuum_rel() calls vacuum_set_xid_limits with the relisshared flag of the relation. vacuum_set_xid_limits passes that to GetOldestXmin as the allDbs parameter. GetOldestXmin ignores transactions not connected to the same database unless allDbs is true. -- greg