Re: v12 and TimeLine switches and backups/restores

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: v12 and TimeLine switches and backups/restores
Дата
Msg-id CA+TgmoYPDxxmYo=r5X8zETN7CL0FSDrUP7wPLy4otUqmZyUJqg@mail.gmail.com
обсуждение исходный текст
Ответ на v12 and TimeLine switches and backups/restores  (Stephen Frost <sfrost@snowman.net>)
Ответы Re: v12 and TimeLine switches and backups/restores  (Stephen Frost <sfrost@snowman.net>)
Список pgsql-hackers
On Wed, Jul 1, 2020 at 12:12 AM Stephen Frost <sfrost@snowman.net> wrote:
> Among the changes made to PG's recovery in v12 was to set
> recovery_target_timeline to be 'latest' by default.  That's handy when
> you're flipping back and forth between replicas and want to have
> everyone follow that game, but it's made doing some basic things like
> restoring from a backup problematic.
>
> Specifically, if you take a backup off a primary and, while that backup
> is going on, some replica is promoted and drops a .history file into the
> WAL repo, that backup is no longer able to be restored with the new
> recovery_target_timeline default.  What happens is that the restore
> process will happily follow the timeline change- even though it happened
> before we reached consistency, and then it'll never find the needed
> end-of-backup WAL point that would allow us to reach consistency.

Ouch. Should we revert that change rather than doing this? Seems like
this might create a lot of problems for people, and they might be
problems that happen rarely enough that it looks like it's working
until it doesn't. What's the fix, if you hit the error? Add
recovery_target_timeline=<the correct timeline> to
postgresql.auto.conf?

Typo: similairly.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Stephen Frost
Дата:
Сообщение: Re: Remove Deprecated Exclusive Backup Mode
Следующее
От: Robert Haas
Дата:
Сообщение: Re: Remove Deprecated Exclusive Backup Mode