From: | Magnus Hagander <magnus(at)hagander(dot)net> |
---|---|
To: | ITAGAKI Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp> |
Cc: | pgsql-patches(at)postgresql(dot)org |
Subject: | Re: O_DIRECT support for Windows |
Date: | 2007-01-15 18:05:28 |
Message-ID: | 45ABC268.1080605@hagander.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
ITAGAKI Takahiro wrote:
> Magnus Hagander <magnus(at)hagander(dot)net> wrote:
>
>> FILE_FLAG_NO_BUFFERING requires that *all* I/O follows:
>> * File access must begin at offsets that are integer multples of the
>> volume sector size.
>> * File access must be for number of bytes that are integer multiples of
>> the volume sector size.
>> * Buffer addresses for read and write operations must be sector aligned.
>>
>> I was under the impression that our code can in no way guarantee this.
>> Especially given that a typical NTFS drive can have anything from 512 to
>> 4096 bytes if you use the GUI to format it, and larger sizes than that
>> when you use some SAN tools to do it.
>
> Do you mean there are drives that have larger sector size than 8kB?
> We've already put the xlog buffer along the alignment of
> ALIGNOF_XLOG_BUFFER (typically 8192 bytes).
> But if there are such drives, using FILE_FLAG_NO_BUFFERING is harmful!
Yes. I have heard this can happen with certain SAN drives. I haven't
seen it myself, and I can't seem to find a reference right now :-) But I
do recall having read about th need to check the sector size and
specifically align it, because some do have that problem.
//Magnus
From | Date | Subject | |
---|---|---|---|
Next Message | Magnus Hagander | 2007-01-15 18:07:29 | Re: [HACKERS] Checkpoint request failed on version 8.2.1. |
Previous Message | Tom Lane | 2007-01-15 17:19:03 | Re: Function execution costs 'n all that |
From | Date | Subject | |
---|---|---|---|
Next Message | Alvaro Herrera | 2007-01-15 18:12:39 | Re: Autovacuum improvements |
Previous Message | Neil Conway | 2007-01-15 17:26:58 | Re: scrollable cursor sup. for SPI |