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 20181204073604.GB6859@paquier.xyz
Whole thread Raw
In response to Re: Use durable_unlink for .ready and .done files for WAL segmentremoval  ("Bossart, Nathan" <bossartn@amazon.com>)
Responses Re: Use durable_unlink for .ready and .done files for WAL segmentremoval  ("Bossart, Nathan" <bossartn@amazon.com>)
List pgsql-hackers
On Thu, Nov 29, 2018 at 03:00:42PM +0000, Bossart, Nathan wrote:
> +1

Okay, here is an updated patch for this stuff, which does the following:
- Check for a WAL segment if it has a ".ready" status file, an orphaned
status file is removed only on ENOENT.
- If durable_unlink fails, retry 3 times.  If there are too many
failures, the archiver gives up on the orphan status file removal.  If
the removal works correctly, the archiver moves on to the next file.

(The variable names could be better.)
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: "myungkyu.lim"
Date:
Subject: RE: [Todo item] Add entry creation timestamp column topg_stat_replication
Next
From: Gilles Darold
Date:
Subject: Re: [PATCH] Log CSV by default