Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id C6327CE6EC for ; Fri, 15 Jun 2012 15:43:47 -0300 (ADT) Received: from gwmta.wicourts.gov ([165.219.244.99] helo=gw.wicourts.gov) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1SfbUp-0007SY-1C for pgsql-performance@postgresql.org; Fri, 15 Jun 2012 18:43:47 +0000 Received: from Courts-MTA by gw.wicourts.gov with Novell_GroupWise; Fri, 15 Jun 2012 13:43:34 -0500 Message-Id: <4FDB3C0202000025000484E4@gw.wicourts.gov> X-Mailer: Novell GroupWise Internet Agent 8.0.2 Date: Fri, 15 Jun 2012 13:43:30 -0500 From: "Kevin Grittner" To: "Benedict Holland" Cc: Subject: Re: Update blocking a select count(*)? References: In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Pg-Spam-Score: -4.2 (----) X-Archive-Number: 201206/80 X-Sequence-Number: 47106 Peter Geoghegan wrote: > Benedict Holland wrote: >> Do I seem to have this right and is there anything I can do? > > There are a couple of maintenance operations that could block a > select. Do you see any AccessExclusive locks within pg_locks? > That's the only type of lock that will block a select statement's > AccessShare lock. To check for that, see the queries on these Wiki pages: http://wiki.postgresql.org/wiki/Lock_Monitoring http://wiki.postgresql.org/wiki/Lock_dependency_information -Kevin