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

Re: O_DIRECT for WAL writes

From: Neil Conway <neilc(at)samurai(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: ITAGAKI Takahiro <itagaki(dot)takahiro(at)lab(dot)ntt(dot)co(dot)jp>,pgsql-patches(at)postgresql(dot)org
Subject: Re: O_DIRECT for WAL writes
Date: 2005-05-30 07:04:41
Message-ID: 1117436681.23266.41.camel@localhost.localdomain (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
On Mon, 2005-05-30 at 02:52 -0400, Tom Lane wrote:
> Some googling suggests so, eg
> http://www.die.net/doc/linux/man/man2/open.2.html

Well, that claims that "data is guaranteed to have been transferred",
but transferred to *where* is the question :) Transferring data to the
disk's buffers and then not asking for the buffer to be flushed is not
sufficient, for example. IMHO the fact that InnoDB uses both O_DIRECT
and fsync() is more convincing. I'm still looking for a definitive
answer, though.

The other question is whether these semantics are identical among the
various O_DIRECT implementations (e.g. Linux, FreeBSD, AIX, IRIX, and
others).

-Neil



In response to

Responses

pgsql-hackers by date

Next:From: Zeugswetter Andreas DAZ SDDate: 2005-05-30 08:01:56
Subject: Re: compiling postgres with Visual Age compiler on OpenPower5 / Linux
Previous:From: Tom LaneDate: 2005-05-30 06:52:09
Subject: Re: O_DIRECT for WAL writes

pgsql-patches by date

Next:From: Pavel StehuleDate: 2005-05-30 07:05:32
Subject: SQLSTATE again
Previous:From: Tom LaneDate: 2005-05-30 06:52:09
Subject: Re: O_DIRECT for WAL writes

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