Re: Use durable_unlink for .ready and .done files for WAL segmentremoval - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: Use durable_unlink for .ready and .done files for WAL segmentremoval
Date
Msg-id 20181127123440.GF1716@paquier.xyz
Whole thread Raw
In response to Re: Use durable_unlink for .ready and .done files for WAL segmentremoval  (Michael Paquier <michael@paquier.xyz>)
Responses Re: Use durable_unlink for .ready and .done files for WAL segmentremoval  ("Bossart, Nathan" <bossartn@amazon.com>)
List pgsql-hackers
On Thu, Nov 22, 2018 at 01:16:09PM +0900, Michael Paquier wrote:
> No, pgarch_readyXLog() should still look after .ready files as those are
> here for this purpose, but we could have an additional check to see if
> the segment linked with it actually exists and can be archived.  This
> check could happen in pgarch.c code before calling the archive command
> gets called (just before pgarch_ArchiverCopyLoop and after
> XLogArchiveCommandSet feels rather right, and that it should be cheap
> enough to call stat()).

s/pgarch_ArchiverCopyLoop/pgarch_archiveXlog/.

Attached is a patch showing shaped based on the idea of upthread.
Thoughts?
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: pgsql: Integrate recovery.conf into postgresql.conf
Next
From: Peter Eisentraut
Date:
Subject: Re: pgsql: Integrate recovery.conf into postgresql.conf