Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ay28i-0000Ag-Lc for pgsql-admin@arkaria.postgresql.org; Wed, 04 May 2016 19:07:16 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1ay28i-0006aC-1Y for pgsql-admin@arkaria.postgresql.org; Wed, 04 May 2016 19:07:16 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1ay28h-0006Zn-Fn for pgsql-admin@postgresql.org; Wed, 04 May 2016 19:07:15 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1ay28e-0007GD-9O for pgsql-admin@postgresql.org; Wed, 04 May 2016 19:07:15 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id u44J77L8017377; Wed, 4 May 2016 15:07:07 -0400 From: Tom Lane To: Alvaro Herrera cc: =?utf-8?B?T25kxZllaiBTdsSbdGzDrWs=?= , pgsql-admin@postgresql.org Subject: Re: Autovacuum of pg_shdepend In-reply-to: <20160504152518.GA102195@alvherre.pgsql> References: <20160504152518.GA102195@alvherre.pgsql> Comments: In-reply-to Alvaro Herrera message dated "Wed, 04 May 2016 12:25:18 -0300" Date: Wed, 04 May 2016 15:07:07 -0400 Message-ID: <17376.1462388827@sss.pgh.pa.us> X-Pg-Spam-Score: -4.0 (----) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-admin Precedence: bulk Sender: pgsql-admin-owner@postgresql.org Alvaro Herrera writes: > Ooh, interesting bug. > As a workaround I suggest connecting to all of your databases except one > and disabling autovacuum for pg_shdepend. Then the table will be > processed in the one database where you left it enabled, and the other > workers will take care of the rest of the tables. > I'll think about a real fix. Seems like a simple answer is to consider all shared catalogs to "belong" to only one database for autovac purposes, ie, only autovac workers in that database would consider vacuuming them. The problem IIUC is that the interlock against multiple workers glomming onto the same table only considers other workers in the same DB. The fun part might be to decide which DB that is. I don't think we should depend on any of the standard databases always being there. regards, tom lane -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin