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 1jlzIN-0001NT-TQ for pgsql-bugs@arkaria.postgresql.org; Thu, 18 Jun 2020 18:29:51 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jlzIM-0005Dn-Ow for pgsql-bugs@arkaria.postgresql.org; Thu, 18 Jun 2020 18:29:50 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jlzIM-0005Df-Im for pgsql-bugs@lists.postgresql.org; Thu, 18 Jun 2020 18:29:50 +0000 Received: from momjian.us ([72.94.173.45]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jlzIJ-0002IY-VZ for pgsql-bugs@lists.postgresql.org; Thu, 18 Jun 2020 18:29:50 +0000 Received: from bruce by momjian.us with local (Exim 4.92) (envelope-from ) id 1jlzIF-0000ct-3q; Thu, 18 Jun 2020 14:29:43 -0400 Date: Thu, 18 Jun 2020 14:29:43 -0400 From: Bruce Momjian To: Stephen Frost Cc: Tom Lane , Jeff Janes , Michael Paquier , ram.maurya@lavainternational.in, pgsql-bugs Subject: Re: BUG #16497: old and new pg_controldata WAL segment sizes are invalid or do not match Message-ID: <20200618182943.GL7349@momjian.us> References: <1549966.1592493410@sss.pgh.pa.us> <20200618152911.GF7349@momjian.us> <20200618154152.GB6680@tamriel.snowman.net> <20200618154854.GG7349@momjian.us> <20200618155537.GC6680@tamriel.snowman.net> <20200618163615.GI7349@momjian.us> <20200618174241.GD6680@tamriel.snowman.net> <20200618180058.GK7349@momjian.us> <20200618181114.GG6680@tamriel.snowman.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200618181114.GG6680@tamriel.snowman.net> User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Thu, Jun 18, 2020 at 02:11:14PM -0400, Stephen Frost wrote: > Greetings, > > * Bruce Momjian (bruce@momjian.us) wrote: > > On Thu, Jun 18, 2020 at 01:42:41PM -0400, Stephen Frost wrote: > > > > > > Yeah, we could add a flag to pg_upgrade to > > > > > > allow this if you are not upgrading replicas, but why bother? It might > > > > > > even work if you create the new replicas with the same WAL segment size, > > > > > > but why add complexity for pg_upgrade, which is already complex enough. > > > > > > > > > > Users already have to deal with various options that need to be > > > > > configured to match up between the primary and replicas, so this really > > > > > seems like it's entirely independent of pg_upgrade and isn't something > > > > > pg_upgrade needs to be worrying about.. > > > > > > > > Do you know why we require this step? > > > > > > > > https://www.postgresql.org/docs/12/pgupgrade.html > > > > > > > > Also, change wal_level to replica in the postgresql.conf file on > > > > the new primary cluster. > > > > > > Well, we'll need wal_level to be at least replica if we're going to have > > > replicas streaming from the primary.. > > > > But how do they have replicas if wal_level = minimum? Also, why not > > higher replication levels? Should we adjust that doc text? > > I think the comment is saying that pg_resetwal will rewrite the > pg_control with a WAL level of minimal and that's the issue and why > the server needs to be brought up with a higher WAL level temporarily, > so that pg_control gets updated, for the new cluster. > > Of course, before pg_upgrade is run, the old cluster would need to be up > and running with a wal_level higher than minimal in order to have > replicas in the first place, but what we're really talking about here is > the new, upgraded, cluster. > > I do think the doc could probably say replica 'or higher'. OK, I will work on that, thanks. -- Bruce Momjian https://momjian.us EnterpriseDB https://enterprisedb.com The usefulness of a cup is in its emptiness, Bruce Lee