X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 94ECB566BB for ; Fri, 18 Mar 2005 07:04:17 +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 30818-08 for ; Fri, 18 Mar 2005 07:04:16 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id 108F456406 for ; Fri, 18 Mar 2005 07:04:14 +0000 (GMT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id j2I74Emf003781; Fri, 18 Mar 2005 02:04:14 -0500 (EST) To: Ron Mayer Cc: pgsql-admin@postgresql.org Subject: Re: Best practice - Vacuum. Replication suggestions and pg vs mysql In-reply-to: References: <27132.1111091610@sss.pgh.pa.us> Comments: In-reply-to Ron Mayer message dated "Thu, 17 Mar 2005 22:38:22 -0800" Date: Fri, 18 Mar 2005 02:04:14 -0500 Message-ID: <3780.1111129454@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.007 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200503/285 X-Sequence-Number: 16783 Ron Mayer writes: > Tom Lane wrote: >> There's no lock, unless you are using VACUUM FULL which you shouldn't. > Or, I believe, if he has any GIST indexes (such as tsearch or > postgis ones). At least it seems normal vacuum locks GIST indexes > for quite some time here. Good point --- gist (and rtree) indexes still don't have any support for concurrent updates, so they have to be locked while VACUUM scans them. > PS: If I'm right, I wonder if VACUUM or at least autovacuum > should automatically force vacuum_cost_delay to zero while > holding locks (i.e. while doing GIST indexes) to reduce the > time those locks are held. Perhaps. VACUUM going at full tilt would cause a system-wide performance impact, though, while the lock only affects processes trying to use or update that index. So you could argue it either way. The best solution would be to fix GIST ;-) regards, tom lane