Re: Use pg_rewind when target timeline was switched
От | Michael Paquier |
---|---|
Тема | Re: Use pg_rewind when target timeline was switched |
Дата | |
Msg-id | CAB7nPqTeKRqcXDOLdabiTksWgDeQ15S4VBG-MyVVW=xV1pg1Lg@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Use pg_rewind when target timeline was switched (Alexander Korotkov <a.korotkov@postgrespro.ru>) |
Ответы |
Re: Use pg_rewind when target timeline was switched
|
Список | pgsql-hackers |
On Fri, Sep 18, 2015 at 9:00 AM, Alexander Korotkov wrote: > BTW, it would be an option to generate system_identifier to each new > timeline, by analogy of initdb do for the whole WAL. > Having such system_identifiers we can distinguish different timeline which > have assigned same ids. > Any thoughts? If you mean a new field incorporated in XLogLongPageHeader and ControlFile to ensure that a new timeline generated is unique across the same installation identified with system_identifier, then I'm not against it for something up to 2 bytes (even 1 byte would be fine), though it seems that there is a very narrow need for it. Do you have cases in mind that could use it? Even in the case of pg_rewind, it seems to me we would not need this extra timeline-based ID. Per your case above, it is possible to rewind node 4 on timeline 3 using node 2 on timeline 2 when both timelines have forked exactly at the same point from timeline 1, by having node 4 beginning to replay from timeline 1 (last checkpoint record before WAL forked), and if I am reading your patch correctly that's what you do. -- Michael
В списке pgsql-hackers по дате отправления: