"E.Rodichev" <[EMAIL PROTECTED]> writes:

> On Thu, 17 Feb 2005, Christopher Kings-Lynne wrote:
>
>> Fsync is so that when your computer loses power without warning, you
>> will have no data loss.
>>
>> If you turn it off, you run the risk of losing data if you lose power.
>>
>> Chris
>
> This problem is addressed by file system (fsck, journalling etc.).
> Is it reasonable to handle it directly within application?

No, it's not addressed by the file system.  fsync() tells the OS to
make sure the data is on disk.  Without that, the OS is free to just
keep the WAL data in memory cache, and a power failure could cause
data from committed transactions to be lost (we don't report commit
success until fsync() tells us the file data is on disk). 

-Doug

---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings

Reply via email to