Warm Standby and resetting the primary as a standby

Поиск
Список
Период
Сортировка
От Derrick Rice
Тема Warm Standby and resetting the primary as a standby
Дата
Msg-id AANLkTi=gimf6K5t78SBQ86K5gbQagWBaCHgkaN53dDA8@mail.gmail.com
обсуждение исходный текст
Ответы Re: Warm Standby and resetting the primary as a standby  (Derrick Rice <derrick.rice@gmail.com>)
Re: Warm Standby and resetting the primary as a standby  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-general
I've been reading up on the documentation for WAL shipping and warm standby configuration. One concern that I have (a common one, I'm sure) is that it seems that after bringing a standby server up as primary, other standby servers (including the original primary) need to be rebased before they can read the new primary's WALs in continuous recovery mode.

It seems that the cause of this is a change to the leading digit of the WAL files:

http://archives.postgresql.org/pgsql-general/2010-03/msg00985.php
http://archives.postgresql.org/pgsql-admin/2009-08/msg00179.php

I was hoping that someone would shed some light on this situation with a technical explanation.  It's not clear to me why the WAL files are incompatible or why the digit increases. What does that first digit mean to postgresql?  Is it possible to have the restore_command ignore the leading digit?

I expected the WAL files to be compatible.  If I start two servers from the same "disk image" and then they get the same exact changes recorded in WAL, why should the next created WAL differ depending on which server creates it?  I imagine these two servers to have identical new versions of a "disk image" after consuming the exact same WALs (one generated them, the other read them).

I'm surprised that this question doesn't come up more often or that there's no explanation in the docs about why its necessary to rebase a primary that went down gracefully (e.g. for planned maintenance)

Thanks

Derrick

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: When is newly inserted data visible to another connection?
Следующее
От: Clemens Eisserer
Дата:
Сообщение: Re: [PERFORM] Are Indices automatically generated for primary keys?