Re: pg_rewind: warn when checkpoint hasn't happened after promotion - Mailing list pgsql-hackers

From Robert Haas
Subject Re: pg_rewind: warn when checkpoint hasn't happened after promotion
Date
Msg-id CA+TgmobSbJ9Z=MxC+i12SUBDnqV9vUmW5zBzAwQyKT=XpOaTwQ@mail.gmail.com
Whole thread Raw
In response to pg_rewind: warn when checkpoint hasn't happened after promotion  (James Coleman <jtc331@gmail.com>)
Responses Re: pg_rewind: warn when checkpoint hasn't happened after promotion
Re: pg_rewind: warn when checkpoint hasn't happened after promotion
List pgsql-hackers
On Sat, Jun 4, 2022 at 8:59 AM James Coleman <jtc331@gmail.com> wrote:
> A quick background refresher: after promoting a standby rewinding the
> former primary requires that a checkpoint have been completed on the
> new primary after promotion. This is correctly documented. However
> pg_rewind incorrectly reports to the user that a rewind isn't
> necessary because the source and target are on the same timeline.

Is there anything intrinsic to the mechanism of operation of pg_rewind
that requires a timeline change, or could we just rewind within the
same timeline to an earlier LSN? In other words, maybe we could just
remove this limitation of pg_rewind, and then perhaps it wouldn't be
necessary to determine what the new timeline is.

-- 
Robert Haas
EDB: http://www.enterprisedb.com



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: PG 15 (and to a smaller degree 14) regression due to ExprEvalStep size
Next
From: Robert Haas
Date:
Subject: Re: pg15b2: large objects lost on upgrade