Re: initdb and fsync - Mailing list pgsql-hackers

From Jeff Janes
Subject Re: initdb and fsync
Date
Msg-id CAMkU=1yXVsN9m8MBcaouVRYwE0ZXeu6r10T64GS3i13Ftj=tgg@mail.gmail.com
Whole thread Raw
In response to Re: initdb and fsync  (Andrew Dunstan <andrew@dunslane.net>)
List pgsql-hackers
On Sat, Jan 28, 2012 at 7:31 AM, Andrew Dunstan <andrew@dunslane.net> wrote:
>
>
> On 01/27/2012 11:52 PM, Noah Misch wrote:
>>>
>>> Is a platform-independent fsync be available at initdb time?
>>
>> Not sure.
>>
>
> It's a macro on Windows that calls _commit(fd), so it should be portable
> enough.
>
> I'm curious what problem we're actually solving here, though. I've run the
> buildfarm countless thousands of times on different VMs, and five of my
> seven current animals run in VMs, and I don't think I've ever seen a failure
> ascribable to inadequately synced files from initdb.

I wouldn't expect you to ever see that problem on the buildfarm.  If
the OS gets thunked during the middle of a regression test, when it
comes back up the code is not going to try to pick up where it left
off, it is just going to blow away the entire install and start over
from scratch.  So any crash-recoverability problems will never be
detected.  I would guess the original poster is doing a more stringent
kind of test.

Cheers,

Jeff


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: initdb and fsync
Next
From: Jeff Davis
Date:
Subject: Re: initdb and fsync