Re: bgwriter and checkpoints

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: bgwriter and checkpoints
Date: 2011-08-12 14:57:47
Message-ID: CA+TgmoZLAj_RocmgtTXJ=zy0JJpKUDuDkB_Xv0KG3+xCH0W51A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Aug 12, 2011 at 9:33 AM, Simon Riggs <simon(at)2ndquadrant(dot)com> wrote:
> Yes, they would still need to talk. But the good news is that they
> only actually need to talk once per checkpoint cycle so we can buffer
> them to a certain extent in shared memory to remove the worst part of
> such contention.

Yeah, some kind of special-purpose communication method between the
cleaning scan and the checkpoint process might help, if the lock
contention turns out to be a problem in practice. Then again, maybe
I'm overthinking things: there's zero sign in any profiling I've done
that BgWriterCommLock is even mildly contended, so even worrying about
it at this point might be a waste of time.

> Checkpointing needs a little more time in its diary to receive those
> messages than it has right now, so there's no easy route.

Yeah.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2011-08-12 15:04:55 Re: WIP: Fast GiST index build
Previous Message Simon Riggs 2011-08-12 13:33:03 Re: bgwriter and checkpoints