Skip site navigation (1) Skip section navigation (2)

Re: [PATCHES] SRA Win32 sync() code

From: Jan Wieck <JanWieck(at)Yahoo(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>,PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>,PostgreSQL Win32 port list <pgsql-hackers-win32(at)postgresql(dot)org>
Subject: Re: [PATCHES] SRA Win32 sync() code
Date: 2003-11-16 20:43:27
Message-ID: 3FB7E16F.8090701@Yahoo.com (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-hackers-win32pgsql-patches
Tom Lane wrote:

> Jan Wieck <JanWieck(at)Yahoo(dot)com> writes:
>> Removing sync() entirely requires very accurate fsync()'ing in the 
>> background writer, the checkpointer and the backends. Basically none of 
>> them can mark a block "clean" if he fails to fsync() the relation later! 
>> This will be a mess to code.
> 
> Not really.  The O_SYNC solution for example would be trivial to code.

Well, the bgwriter has basically the same chance the checkpointer has 
... mdblindwrt() in the end, because he doesn't have the relcache handy. 
So you want to open(O_SYNC), write(), close() every single block? I 
don't expect that to be much better than a global sync().


Jan

-- 
#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#================================================== JanWieck(at)Yahoo(dot)com #


In response to

Responses

pgsql-hackers by date

Next:From: David FetterDate: 2003-11-16 21:13:33
Subject: Bittorrent test
Previous:From: Tom LaneDate: 2003-11-16 20:17:08
Subject: Re: [PATCHES] SRA Win32 sync() code

pgsql-patches by date

Next:From: Rod TaylorDate: 2003-11-16 21:58:43
Subject: Alter Table phase 1 -- Please apply to 7.5
Previous:From: Tom LaneDate: 2003-11-16 20:17:08
Subject: Re: [PATCHES] SRA Win32 sync() code

pgsql-hackers-win32 by date

Next:From: Tom LaneDate: 2003-11-16 22:46:17
Subject: Re: [PATCHES] SRA Win32 sync() code
Previous:From: Tom LaneDate: 2003-11-16 20:17:08
Subject: Re: [PATCHES] SRA Win32 sync() code

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group