Re: Hot Standby: Startup at shutdown checkpoint

Поиск
Список
Период
Сортировка
Искать
От
Robert Haas
Тема
Re: Hot Standby: Startup at shutdown checkpoint
Дата
Msg-id
p2t603c8f071004080649m972635bbr86c08be2441741f6@mail.gmail.com
Ответ на
Список
Дерево обсуждения
Hot Standby: Startup at shutdown checkpoint Simon Riggs <simon@2ndQuadrant.com>
Re: Hot Standby: Startup at shutdown checkpoint Simon Riggs <simon@2ndQuadrant.com>
Re: Hot Standby: Startup at shutdown checkpoint Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Re: Hot Standby: Startup at shutdown checkpoint Simon Riggs <simon@2ndQuadrant.com>
Re: Hot Standby: Startup at shutdown checkpoint Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Re: Hot Standby: Startup at shutdown checkpoint Simon Riggs <simon@2ndQuadrant.com>
Re: Hot Standby: Startup at shutdown checkpoint Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Re: Hot Standby: Startup at shutdown checkpoint Simon Riggs <simon@2ndQuadrant.com>
Re: Hot Standby: Startup at shutdown checkpoint Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Re: Hot Standby: Startup at shutdown checkpoint Simon Riggs <simon@2ndQuadrant.com>
Re: Hot Standby: Startup at shutdown checkpoint Robert Haas <robertmhaas@gmail.com>
On Thu, Apr 8, 2010 at 6:16 AM, Simon Riggs  wrote:
> If standby_mode is enabled and there is no source of WAL, then we get a
> stream of messages saying
>
> LOG:  record with zero length at 0/C000088
> ...
>
> but most importantly we never get to the main recovery loop, so Hot
> Standby never gets to start at all. We can't keep retrying the request
> for WAL and at the same time enter the retry loop, executing lots of
> things that expect non-NULL pointers using a NULL xlog pointer.

This is pretty much a corner case, so I don't think it's a good idea
to add a new mode to handle it.  It also seems like it would be pretty
inconsistent if we allow WAL to be dropped in pg_xlog, but only if we
are also doing archive recovery or streaming replication.  If we can't
support this case with the same code path we use otherwise, I think we
should revert to disallowing it.

Having said that, I guess I don't understand how having a source of
WAL solves the problem described above.  Do we always have to read at
least 1 byte of WAL from either SR or the archive before starting up?
If not, why do we need to do so here?

...Robert

В списке pgsql-hackers по дате отправления
От: Robert Haas
Дата:
От: Olivier Baheux
Дата:
FAQ