Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lOiSy-0002gB-1L for pgsql-hackers@arkaria.postgresql.org; Tue, 23 Mar 2021 14:57:08 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lOiSR-0001Kg-Cg for pgsql-hackers@arkaria.postgresql.org; Tue, 23 Mar 2021 14:56:35 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lOiSR-0001JY-5q for pgsql-hackers@lists.postgresql.org; Tue, 23 Mar 2021 14:56:35 +0000 Received: from momjian.us ([72.94.173.45]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lOiSP-0003Tw-82 for pgsql-hackers@postgresql.org; Tue, 23 Mar 2021 14:56:34 +0000 Received: from bruce by momjian.us with local (Exim 4.92) (envelope-from ) id 1lOiSK-0003Ux-W7; Tue, 23 Mar 2021 10:56:28 -0400 Date: Tue, 23 Mar 2021 10:56:28 -0400 From: Bruce Momjian To: Jan Wieck Cc: Zhihong Yu , Andrew Dunstan , Tom Lane , Magnus Hagander , Robins Tharakan , Peter Eisentraut , "pgsql-hackers@postgresql.org" Subject: Re: pg_upgrade failing for 200+ million Large Objects Message-ID: <20210323145628.GD579@momjian.us> References: <1743618.1615222719@sss.pgh.pa.us> <4fbf92f2-ec91-f4fa-a259-f0968e34f3d7@wi3ck.info> <181907.1616253799@sss.pgh.pa.us> <147fa478-510b-18ef-5323-9c1725b2493c@wi3ck.info> <5bdcb010-ecdd-c69a-b441-68002fc38483@wi3ck.info> <3886649c-c77d-dfd7-08a4-d1606bc71254@wi3ck.info> <91ccdb0d-42fd-7413-4e7c-3d6445655d2e@wi3ck.info> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <91ccdb0d-42fd-7413-4e7c-3d6445655d2e@wi3ck.info> User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Tue, Mar 23, 2021 at 08:51:32AM -0400, Jan Wieck wrote: > On 3/22/21 7:18 PM, Jan Wieck wrote: > > On 3/22/21 5:36 PM, Zhihong Yu wrote: > > > Hi, > > > > > > w.r.t. pg_upgrade_improvements.v2.diff. > > > > > > +       blobBatchCount = 0; > > > +       blobInXact = false; > > > > > > The count and bool flag are always reset in tandem. It seems > > > variable blobInXact is not needed. > > > > You are right. I will fix that. > > New patch v3 attached. Would it be better to allow pg_upgrade to pass arbitrary arguments to pg_restore, instead of just these specific ones? -- Bruce Momjian https://momjian.us EDB https://enterprisedb.com If only the physical world exists, free will is an illusion.