Re: [HACKERS] issue about the streaming replication

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [HACKERS] issue about the streaming replication
Дата
Msg-id CAB7nPqSWc=tM2kniOAXfcGzPdDLTfaaX77FRBReQtr86LXtRUw@mail.gmail.com
обсуждение исходный текст
Ответ на [HACKERS] issue about the streaming replication  (Jinhua Luo <luajit.io@gmail.com>)
Ответы Re: [HACKERS] issue about the streaming replication  (Jinhua Luo <luajit.io@gmail.com>)
Список pgsql-hackers
On Sun, Mar 12, 2017 at 5:24 PM, Jinhua Luo <luajit.io@gmail.com> wrote:
> I think this diverge scenario is common, because it's likely the
> master would crash due to some hardware issue (e.g. power off) which
> would cause some committed transaction has not yet synced to slave,
> while the slave would be promoted to new master and accepts new
> transactions, then how to recover the old master? Moreover, how to
> recover the data on old master which is missing on new master?

pg_rewind (https://www.postgresql.org/docs/9.6/static/app-pgrewind.html)
has been designed with exactly this scenario in mind, aka recycling a
past master as a slave to a promoted node. Have you looked at it? What
you are trying to do is much likely going to create corruptions on
your systems, so I am not surprised that you see inconsistency
failures, what you are seeing is pretty much the tip of hte iceberg.
-- 
Michael



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

Предыдущее
От: Jinhua Luo
Дата:
Сообщение: [HACKERS] issue about the streaming replication
Следующее
От: Jinhua Luo
Дата:
Сообщение: Re: [HACKERS] issue about the streaming replication