On 2016-09-02 13:05:37 -0400, Tom Lane wrote:
> Anderson Carniel <accarn...@gmail.com> writes:
> > If not, according to your experience, is there a
> > significance difference between the performance of the O_DIRECT or not?
> 
> AFAIK, nobody's really bothered to measure whether that would be useful
> for Postgres.  The results would probably be quite platform-specific
> anyway.

I've played with patches to make postgres use O_DIRECT. On linux, it's
rather beneficial for some workloads (fits into memory), but it also
works really badly for some others, because our IO code isn't
intelligent enough.  We pretty much rely on write() being nearly
instantaneous when done by normal backends (during buffer replacement),
we rely on readahead, we rely on the kernel to stopgap some bad
replacement decisions we're making.

Andres


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to