Re: Re: [COMMITTERS] pgsql: Make standby server continuously retry restoring the next WAL

Поиск
Список
Период
Сортировка
От Fujii Masao
Тема Re: Re: [COMMITTERS] pgsql: Make standby server continuously retry restoring the next WAL
Дата
Msg-id 3f0b79eb1003240620h209a0a40ud2063728b5db31a6@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Re: [COMMITTERS] pgsql: Make standby server continuously retry restoring the next WAL  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Ответы Re: Re: [COMMITTERS] pgsql: Make standby server continuously retry restoring the next WAL  (Fujii Masao <masao.fujii@gmail.com>)
Re: Re: [COMMITTERS] pgsql: Make standby server continuously retry restoring the next WAL  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Список pgsql-hackers
On Wed, Mar 24, 2010 at 9:31 PM, Heikki Linnakangas
<heikki.linnakangas@enterprisedb.com> wrote:
> Hmm, true, this changes behavior over previous releases. I tend to think
> that it's always an error if there's a corrupt file in the archive,
> though, and PANIC is appropriate. If the administrator wants to start up
> the database anyway, he can remove the corrupt file from the archive and
> place it directly in pg_xlog instead.

Okay.

> Thanks. That's easily fixable (applies over the previous patch):
>
> --- a/src/backend/access/transam/xlog.c
> +++ b/src/backend/access/transam/xlog.c
> @@ -3773,7 +3773,7 @@ retry:
>                pagelsn.xrecoff = 0;
>            }
>            /* Wait for the next page to become available */
> -           if (!XLogPageRead(&pagelsn, emode, false, false))
> +           if (!XLogPageRead(&pagelsn, emode_arg, false, false))
>                return NULL;
>
>            /* Check that the continuation record looks valid */

Seems correct.

> sources &= ~failedSources;
> failedSources |= readSource;

The above lines in XLogPageRead() seem not to be required in normal
recovery case (i.e., standby_mode = off). So how about the attached
patch?

Regards,

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

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: PHONY targets in Makefile.global.in
Следующее
От: Fujii Masao
Дата:
Сообщение: Re: Re: [COMMITTERS] pgsql: Make standby server continuously retry restoring the next WAL