From: | Mark Kirkwood <mark(dot)kirkwood(at)catalyst(dot)net(dot)nz> |
---|---|
To: | Stephen Frost <sfrost(at)snowman(dot)net> |
Cc: | Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Clean switchover |
Date: | 2013-06-12 03:55:21 |
Message-ID: | 51B7F129.5080700@catalyst.net.nz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 12/06/13 13:15, Stephen Frost wrote:
> * Fujii Masao (masao(dot)fujii(at)gmail(dot)com) wrote:
>> The attached patch fixes this problem. It just changes walsender so that it
>> waits for all the outstanding WAL records to be replicated to the standby
>> before closing the replication connection.
>
> Seems like a good idea to me.. Rather surprised that we're not doing
> this already, to be honest.
>
Yeah +1 from here too. This would make clean switchovers for (typically)
testing scenarios a lot less complex and resource intensive (rebuilding
of the old master as a slave when you know it is ok is despairing on a
huge db).
On the related note (but not actually to do with this patch),
clarifying/expanding the docs about the various methods for standby
promotion:
1/ trigger file creation
2/ pg_ctl promote
3/ renaming/removing recovery.conf
and the differences between them would be great. For instance I only
recently realized that method 3) means the promoted standby does not
start a new timeline (incidentally - could this be an option to pg_ctl
promote) which is very useful for (again) controlled/clean switchovers.
regards
Mark
From | Date | Subject | |
---|---|---|---|
Next Message | Craig Ringer | 2013-06-12 04:13:17 | Re: JSON and unicode surrogate pairs |
Previous Message | David E. Wheeler | 2013-06-12 03:50:53 | Re: [PATCH] Exorcise "zero-dimensional" arrays (Was: Re: Should array_length() Return NULL) |