Re: Unarchived WALs deleted after crash

From: Simon Riggs <simon(at)2ndQuadrant(dot)com>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: Heikki Linnakangas <hlinnakangas(at)vmware(dot)com>, Jehan-Guillaume de Rorthais <jgdr(at)dalibo(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Unarchived WALs deleted after crash
Date: 2013-02-15 17:49:04
Message-ID: CA+U5nML55uusMTENGr=bkO35GFEqgO=sWCdktJuoOdt_5XDb9w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 15 February 2013 16:10, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:

>> I propose the attached patch to fix it.
>
> At least in 9.2, when the archived file is restored into pg_xlog, its xxx.done
> archive status file is created. So we don't need to check InArchiveRecovery
> when deleting old WAL files. Checking whether xxx.done exists is enough.

I don't agree. The extra test Heikki put in was useful and helps avoid
issues when we get the .done creation wrong, or when people delete
them.

--
Simon Riggs http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Atri Sharma 2013-02-15 18:20:33 Re: [pgsql-advocacy] Call for Google Summer of Code mentors, admins
Previous Message Peter Eisentraut 2013-02-15 17:44:30 Re: Materialized views WIP patch