Re: streaming replication master can fail to shut down
| От | Andres Freund |
|---|---|
| Тема | Re: streaming replication master can fail to shut down |
| Дата | |
| Msg-id | 20160428181424.u5bzgbhk77va7j24@alap3.anarazel.de обсуждение исходный текст |
| Ответ на | Re: streaming replication master can fail to shut down (Nick Cleaton <nick@cleaton.net>) |
| Ответы |
Re: streaming replication master can fail to shut down
|
| Список | pgsql-bugs |
Hi,
On 2016-03-11 14:12:37 +0000, Nick Cleaton wrote:
> This patch is enough to eliminate the problem on my hardware
> diff -Nurd postgresql-9.5.1.orig/src/backend/replication/walsender.c
postgresql-9.5.1/src/backend/replication/walsender.c
> --- postgresql-9.5.1.orig/src/backend/replication/walsender.c 2016-02-08 21:12:28.000000000 +0000
> +++ postgresql-9.5.1/src/backend/replication/walsender.c 2016-03-11 11:56:41.121361222 +0000
> @@ -2502,8 +2502,10 @@
>
> proc_exit(0);
> }
> - if (!waiting_for_ping_response)
> + if (!waiting_for_ping_response) {
> WalSndKeepalive(true);
> + waiting_for_ping_response = true;
> + }
> }
That looks (besides non-postges paren placement), reasonable. Will
commit & backpatch (to 9.4, where it looks like the bug has been
introduced).
> in this test the server sent only 29 keepalives during the shutdown:
> http://nick.cleaton.net/protodump-100k-nossl-patched.xz (47k)
I guess you have a fair amount of WAL traffic, and the receiver was
behind a good bit?
Greetings,
Andres Freund
В списке pgsql-bugs по дате отправления: