Re: Potential data loss of 2PC files

From: Andres Freund <andres(at)anarazel(dot)de>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>,PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Potential data loss of 2PC files
Date: 2016-12-22 18:02:39
Message-ID: A6F96364-6E68-466C-8E31-206AAD7FD14C@anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On December 22, 2016 6:44:22 PM GMT+01:00, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
>On Thu, Dec 22, 2016 at 12:39 PM, Andres Freund <andres(at)anarazel(dot)de>
>wrote:
>> It makes more sense of you mentally separate between filename(s) and
>file contents. Having to do filesystem metatata transactions for an
>fsync intended to sync contents would be annoying...
>
>I thought that's why there's fdatasync.

Not quite IIRC: that doesn't deal with file size increase. All this would be easier if hardlinks wouldn't exist IIUC. It's basically a question whether dentry, inode or contents need to be synced. Yes, it sucks.

Andres
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tomas Vondra 2016-12-22 18:08:43 Re: increasing the default WAL segment size
Previous Message Tomas Vondra 2016-12-22 17:59:50 Re: An attempt to reduce WALWriteLock contention