On 03/26/2015 09:45 PM, Arthur Silva wrote:
> On Mar 26, 2015 4:20 AM, "Vladimir Borodin" <root@simply.name> wrote:
>>
>>
>>> 26 марта 2015 г., в 7:32, Michael Paquier <michael.paquier@gmail.com>
> написал(а):
>>>
>>> On Thu, Mar 26, 2015 at 12:23 PM, Venkata Balaji N <nag1010@gmail.com>
> wrote:
>>>> If the master is crashed or killed abruptly, it may not be possible to
> do a
>>>> rewind. Is my understanding correct ?
>>>
>>> Yep. This is mentioned in the documentation:
>>> http://www.postgresql.org/docs/devel/static/app-pgrewind.html
>>> "The target server must shut down cleanly before running pg_rewind>>.
>>
>> You can start old master, wait for crash recovery to complete, stop it
> cleanly and then use pg_rewind. It works.
>
> Shouldn't we have a flag so it does that automatically if necessary?
Might be handy, but currently pg_rewind never invokes postgres or other
binaries, so it would be a fair amount of new functionality to implement
that. Let's keep it simple for now.
- Heikki