From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: RelationCreateStorage can orphan files |
Date: | 2010-09-16 02:32:38 |
Message-ID: | AANLkTind-RQhMeTEHNNV3pK3xm4z3jT8ucOmLEstV1oX@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Sep 15, 2010 at 10:32 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
>> On Wed, Sep 15, 2010 at 9:16 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>>> That design is intentional. If the file create fails, and you've
>>> already written a WAL record that says you created it, you are flat
>>> out screwed. You can't even PANIC --- if you do, then the replay of
>>> the WAL record will likely fail and PANIC again, leaving the database
>>> dead in the water.
>
>> Not that this is perhaps more than of academic interest, but could you
>> get around this problem by making the replay of the XLOG record defer
>> the creation of the file until such time as it's actually written to
>> or the creating XID commits? And also, if the XID does not commit,
>> going back and trying to remove the file (on a best effort basis)?
>
> Perhaps, but it seems like a lot more complexity than is justified
> by the problem.
That's sort of what I figured.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company
From | Date | Subject | |
---|---|---|---|
Next Message | Fujii Masao | 2010-09-16 04:23:19 | Re: Latches, signals, and waiting |
Previous Message | Tom Lane | 2010-09-16 02:32:05 | Re: RelationCreateStorage can orphan files |