Re: Allowing WAL fsync to be done via O_SYNC - Mailing list pgsql-hackers

From Ken Hirsch
Subject Re: Allowing WAL fsync to be done via O_SYNC
Date
Msg-id OE4IjmMPqngL6wxvw0I00000ae5@hotmail.com
Whole thread Raw
In response to Re: Re[2]: Allowing WAL fsync to be done via O_SYNC  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-hackers
From: "Bruce Momjian" <pgman@candle.pha.pa.us>
> > > Could anyone consider fork a syncer process to sync data to disk ?
> > > build a shared sync queue, when a daemon process want to do sync after
> > > write() is called, just put a sync request to the queue. this can
release
> > > process from blocked on writing as soon as possible. multipile sync
> > > request for one file can be merged when the request is been inserting
to
> > > the queue.
> >
> > I suggested this about a year ago. :)
> >
> > The problem is that you need that process to potentially open and close
> > many files over and over.
> >
> > I still think it's somewhat of a good idea.
>
> I like the idea too, but people want the transaction to return COMMIT
> only after data has been fsync'ed so I don't see a big win.

For a log file on a busy system, this could improve throughput a lot--batch
commit.  You end up with fewer than one fsync() per transaction.




pgsql-hackers by date:

Previous
From: Alfred Perlstein
Date:
Subject: Re: Re[2]: Allowing WAL fsync to be done via O_SYNC
Next
From: Tom Lane
Date:
Subject: Re: AW: Allowing WAL fsync to be done via O_SYNC