Re: [Lsf-pc] Linux kernel impact on PostgreSQL performance

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: James Bottomley <James(dot)Bottomley(at)hansenpartnership(dot)com>, Andres Freund <andres(at)2ndquadrant(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, Hannu Krosing <hannu(at)2ndquadrant(dot)com>, Trond Myklebust <trondmy(at)gmail(dot)com>, Kevin Grittner <kgrittn(at)ymail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>, Dave Chinner <david(at)fromorbit(dot)com>, Joshua Drake <jd(at)commandprompt(dot)com>, Claudio Freire <klaussfreire(at)gmail(dot)com>, Mel Gorman <mgorman(at)suse(dot)de>, "lsf-pc(at)lists(dot)linux-foundation(dot)org" <lsf-pc(at)lists(dot)linux-foundation(dot)org>, Magnus Hagander <magnus(at)hagander(dot)net>
Subject: Re: [Lsf-pc] Linux kernel impact on PostgreSQL performance
Date: 2014-01-14 17:47:10
Message-ID: 20056.1389721630@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> On Tue, Jan 14, 2014 at 11:57 AM, James Bottomley
> <James(dot)Bottomley(at)hansenpartnership(dot)com> wrote:
>> No, I do ... you mean the order of write out, if we have to do it, is
>> important. In the rest of the kernel, we do this with barriers which
>> causes ordered grouping of I/O chunks. If we could force a similar
>> ordering in the writeout code, is that enough?

> Probably not. There are a whole raft of problems here. For that to
> be any of any use, we'd have to move to mmap()ing each buffer instead
> of read()ing them in, and apparently mmap() doesn't scale well to
> millions of mappings.

We would presumably mmap whole files, not individual pages (at least
on 64-bit machines; else address space size is going to be a problem).
However, without a fix for the critical-section/atomic-update problem,
the idea's still going nowhere.

> This would be pretty similar to copy-on-write, except without the
> copying. It would just be forget-from-the-buffer-pool-on-write.

That might possibly work.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Marko Tiikkaja 2014-01-14 17:51:09 Re: plpgsql.consistent_into
Previous Message Thom Brown 2014-01-14 17:43:20 Re: shared memory message queues