Re: Streaming replication, and walsender during recovery

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Streaming replication, and walsender during recovery
Date: 2010-01-29 11:25:35
Message-ID: 3f0b79eb1001290325j1aa24dddif3b373efc84cfa44@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jan 29, 2010 at 5:41 PM, Simon Riggs <simon(at)2ndquadrant(dot)com> wrote:
>> To improve the situation, I think that we need to use
>> checkpoint_segment/timeout as a trigger of restartpoint, regardless
>> of the checkpoint record. Though I'm not sure that is possible and
>> should be included in v9.0.
>
> Yes, that is a simple change. I think it is needed now.

On second thought, it's difficult to force restartpoint without
a checkpoint record. A recovery always needs to start from a
checkpoint redo location. Otherwise a torn page might be caused
because a full-page image has not been replayed. So restartpoint
will not start without a checkpoint record.

But at least we might have to change the bgwriter so as to use
not only checkpoint_timeout but also checkpoint_segments as a
trigger of restartpoint. It would be useful for people who want
to control the cycle of checkpoint by using only checkpoint_segments.

Regards,

--
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tim Bunce 2010-01-29 11:33:43 Re: Add on_perl_init and proper destruction to plperl UPDATED [PATCH]
Previous Message Fujii Masao 2010-01-29 10:40:13 Re: Streaming replication and pg_xlogfile_name()