Re: BUG #16497: old and new pg_controldata WAL segment sizes are invalid or do not match - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #16497: old and new pg_controldata WAL segment sizes are invalid or do not match
Date
Msg-id 1549966.1592493410@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #16497: old and new pg_controldata WAL segment sizes areinvalid or do not match  (Jeff Janes <jeff.janes@gmail.com>)
Responses Re: BUG #16497: old and new pg_controldata WAL segment sizes areinvalid or do not match
Re: BUG #16497: old and new pg_controldata WAL segment sizes areinvalid or do not match
List pgsql-bugs
Jeff Janes <jeff.janes@gmail.com> writes:
> Since wal-segsize is changeable with pg_resetwal since v11, and pg_upgrade
> is already calling pg_resetwal, shouldn't pg_upgrade ideally just deal with
> this situation automatically by allowing the upgrade to also change this
> value, rather than forcing the user to make them match manually?

The issue is that this is an initdb parameter, and pg_upgrade expects you
to have already initdb'd the destination cluster.  We could redefine that,
perhaps, but it'd be a large change in how one uses pg_upgrade and would
certainly break a lot of scripts.

I'm aware that we could use pg_resetwal to deal with this one specific
initdb parameter, but I see no point in hacking around the problem for
just one parameter.  The general principle remains that you need to
initdb the target with the same settings you used for the source.

            regards, tom lane



pgsql-bugs by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: BUG #16497: old and new pg_controldata WAL segment sizes areinvalid or do not match
Next
From: Bruce Momjian
Date:
Subject: Re: BUG #16497: old and new pg_controldata WAL segment sizes areinvalid or do not match