From: | Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com> |
---|---|
To: | Jeff Davis <pgsql(at)j-davis(dot)com> |
Cc: | pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: Recovery bug |
Date: | 2010-10-26 18:48:44 |
Message-ID: | 4CC7228C.7020002@enterprisedb.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
On 26.10.2010 10:48, Heikki Linnakangas wrote:
> On 25.10.2010 19:04, Jeff Davis wrote:
>> On Mon, 2010-10-25 at 14:44 +0300, Heikki Linnakangas wrote:
>>> It seems we should use ReadRecord instead of the lower-level
>>> XLogPageRead function. One difference is that ReadRecord performs a
>>> bunch of sanity checks on the record, while XLogPageRead just reads the
>>> raw page. Extra sanity checking before removing backup_label seems like
>>> a good idea. Another difference is that in standby-mode, ReadRecord will
>>> retry until it succeeds. A standby server should keep retrying, even the
>>> very first record, until it succeeds, otherwise we have a change in
>>> behavior.
>>
>> The reason I didn't use ReadRecord is because it sets a global variable
>> to point to the next location in the log, so that subsequent calls can
>> just pass NULL for the location.
>
> True. XLogPageRead is new in 9.0, however. We'll have to use ReadRecord
> or invent something new for back-branches anyway.
Ok, committed the patch I posted earlier today using ReadRecord.
--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com
From | Date | Subject | |
---|---|---|---|
Next Message | Simon Riggs | 2010-10-26 21:16:02 | Re: BUG #5727: Indexes broken in streaming replication |
Previous Message | Tom Lane | 2010-10-26 18:08:15 | Re: BUG #5727: Indexes broken in streaming replication |