Re: Full page images in WAL & Cache Invalidation

From: "Florian G(dot) Pflug" <fgp(at)phlo(dot)org>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Full page images in WAL & Cache Invalidation
Date: 2007-07-23 17:36:43
Message-ID: 46A4E72B.4030105@phlo.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Simon Riggs wrote:
> On Sun, 2007-07-22 at 19:58 +0200, Florian G. Pflug wrote:
>> Tom Lane wrote:
>>> "Florian G. Pflug" <fgp(at)phlo(dot)org> writes:
>>>> I'm currently working on correctly flushing the
>>>> catalog/relation/sgmr caches on a readonly PITR
>>>> slave during recovery.
>>> I don't believe there is any workable solution to that short of logging
>>> cache-flush operations in WAL.
>
>> The reason that I dislike WAL-logging of the flush operations so much is
>> that it since peopel are concerned about the amount of wal traffic
>> postgres generated, such a solution would introduce yet another GUC.
>> And to make this reasonable foolproof, the slave would need a way to
>> detect if that GUC is set correctly on the master. All in all, that
>> seems to be quite hackish...
>
> Seems like we should WAL log flush operations first. It's fairly
> straightforward to do that and we can then measure its effect on the
> primary easily enough. Your other suggestions seem much more complex.
>
> I think we have a reasonable tolerance for increases in WAL and as you
> said earlier, we may balance that out with other optimisations. Or we
> may find a more efficient way of doing it later.
>
> Let's aim to get that first query running, then go back and tune it
> later.

I've so far added an LWLock that makes replay and queries mutually
exclusive, Simple testcases seem to work, but I haven't really
beaten the system yet...

Of course, my current version falls over as soon as you do
DDL on the master - working on fixing that, and on
subsequently removing that lock again :-)

greetings, Florian Pflug

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2007-07-23 17:44:03 Re: [HACKERS] 8.2.4 signal 11 with large transaction
Previous Message Magnus Hagander 2007-07-23 17:30:32 Re: Oops in fe-auth.c