From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | SATYANARAYANA NARLAPURAM <satyanarlapuram(at)gmail(dot)com> |
Cc: | Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Postgres restart in the middle of exclusive backup and the presence of backup_label file |
Date: | 2021-11-24 22:45:46 |
Message-ID: | YZ7Amotspa4ve+91@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Nov 24, 2021 at 02:12:19PM -0800, SATYANARAYANA NARLAPURAM wrote:
> While an exclusive backup is in progress if Postgres restarts, postgres
> runs the recovery from the checkpoint identified by the label file instead
> of the control file. This can cause long recovery or even sometimes fail to
> recover as the WAL records corresponding to that checkpoint location are
> removed. I can write a layer in my control plane to remove the backup_label
> file when I know the server is not in restore from the base backup but I
> don't see a reason why everyone has to repeat this step. Am I missing
> something?
This is a known issue with exclusive backups, which is a reason why
non-exclusive backups have been implemented. pg_basebackup does that,
and using "false" as the third argument of pg_start_backup() would
have the same effect. So I would recommend to switch to that.
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Dunstan | 2021-11-24 22:55:03 | Re: Reduce function call costs on ELF platforms |
Previous Message | Tom Lane | 2021-11-24 22:16:50 | Re: internal subtransactions, memory contexts, resource owners |