Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hjVIH-0001lp-Fs for pgsql-bugs@arkaria.postgresql.org; Fri, 05 Jul 2019 20:58:57 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hjVIG-0004jv-Ab for pgsql-bugs@arkaria.postgresql.org; Fri, 05 Jul 2019 20:58:56 +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_SHA1:256) (Exim 4.89) (envelope-from ) id 1hjVIG-0003v5-2e for pgsql-bugs@lists.postgresql.org; Fri, 05 Jul 2019 20:58:56 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hjVHr-0005p9-To for pgsql-bugs@lists.postgresql.org; Fri, 05 Jul 2019 20:58:35 +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 x65Kvxiu027095; Fri, 5 Jul 2019 16:57:59 -0400 From: Tom Lane To: Alvaro Herrera cc: Robert Haas , Manuel Rigger , PostgreSQL mailing lists Subject: Re: VACUUM FULL results in deadlock In-reply-to: <20190705161433.GA29023@alvherre.pgsql> References: <20190705161433.GA29023@alvherre.pgsql> Comments: In-reply-to Alvaro Herrera message dated "Fri, 05 Jul 2019 12:14:33 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <27093.1562360279.1@sss.pgh.pa.us> Date: Fri, 05 Jul 2019 16:57:59 -0400 Message-ID: <27094.1562360279@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Alvaro Herrera writes: > I agree that you should not be running 32 full vacuums at once, much > less in a loop, but if you do, they shouldn't result in weird corruption > such as the ones reported. BTW, looking at the OIDs in the original problem report, they are for pg_authid and pg_shdepend, both of which are shared catalogs. It does not seem terribly surprising to me that sets of operations that take out exclusive locks on such catalogs are subject to deadlocks, especially not when you consider that yet other sessions also have need to read those catalogs. So I'm more or less in agreement with Robert that the deadlock errors aren't very interesting. But I still concur with Alvaro that those other error messages probably shouldn't be happening. regards, tom lane