RE: Missing WAL file after running pg_rewind

Поиск
Список
Период
Сортировка
От Dylan Luong
Тема RE: Missing WAL file after running pg_rewind
Дата
Msg-id 388af9edaa97460f8fcc528df9cc9ce7@ITUPW-EXMBOX3B.UniNet.unisa.edu.au
обсуждение исходный текст
Ответ на Re: Missing WAL file after running pg_rewind  (Michael Paquier <michael.paquier@gmail.com>)
Ответы Re: Missing WAL file after running pg_rewind  (Michael Paquier <michael.paquier@gmail.com>)
Список pgsql-general
The content of the history file 00000006.history is:

$ more 00000006.history
1       2CE/8A000098    no recovery target specified
2       2CE/FF974EF0    no recovery target specified
3       2CF/51000098    no recovery target specified
4       2D1/C90ACD88    no recovery target specified
5       383/C0790E50    no recovery target specified

Here are the last few archive file of the old timeline (old master):

0000000500000383000000BD
0000000500000383000000BE
0000000500000383000000BF
0000000500000383000000C0
0000000500000383000000C1

Here are the first few archive files of the new timeline (new master):
0000000500000383000000C0.partial
0000000600000383000000C0
0000000600000383000000C1
0000000600000383000000C2
0000000600000383000000C3

Looks like it has folked at C0.
But why is the new slave asking for 0000000600000383000000BE on timeline during the restore after the pg_rewind? And
notfrom C0? 

Dylan


-----Original Message-----
From: Michael Paquier [mailto:michael.paquier@gmail.com]
Sent: Saturday, 13 January 2018 9:04 PM
To: Dylan Luong <Dylan.Luong@unisa.edu.au>
Cc: pgsql-general@lists.postgresql.org
Subject: Re: Missing WAL file after running pg_rewind

On Fri, Jan 12, 2018 at 09:44:25PM +0000, Dylan Luong wrote:
> The file  exist in the archive directory of the old master but it is
> for the previous timeline, ie 5 and not 6, ie
> 0000000500000383000000BE. Can I just rename the file to 6 timeline? Ie
> 0000000600000383000000BE

What are the contents of the history file for this new timeline? You are looking at 00000006.history which should be
archivedas well. You could do that assuming that WAL has forked on this segment at promotion as both segments would
havethe same contents up to the point where WAL has forked. 
--
Michael


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

Предыдущее
От: Vick Khera
Дата:
Сообщение: Re: psql format result as markdown tables
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: Missing WAL file after running pg_rewind