Re: SRA Win32 sync() code - Mailing list pgsql-patches

From Manfred Spraul
Subject Re: SRA Win32 sync() code
Date
Msg-id 3FB7B189.50308@colorfullife.com
Whole thread Raw
In response to Re: SRA Win32 sync() code  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: SRA Win32 sync() code
Re: SRA Win32 sync() code
List pgsql-patches
Tom Lane wrote:

>Seriously though, if we can move the bulk of the writing work into
>background processes then I don't believe that there will be any
>significant penalty for regular backends.  And I believe that it would
>be a huge advantage from a correctness point of view if we could stop
>depending on sync().
>
Which function guarantees that renames of WAL files arrived on the disk?
AFAIK sync() is the only function that guarantees that.

What about the sync app from sysinternals? It seems Mark Russinovich
figured out how to implement sync on Win32:
http://www.sysinternals.com/ntw2k/source/misc.shtml#Sync

It requires administrative priveledges, but it shouldn't be that
difficult to write a tiny service that runs in the LocalSystem account,
listens to a pipe and syncs all disks when asked.

--
    Manfred


pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: improve overcommit docs
Next
From: Andrew Dunstan
Date:
Subject: Re: improve overcommit docs