Re: Primary keepalive message not appearing in Logical StreamingReplication

Поиск
Список
Период
Сортировка
От Tomas Vondra
Тема Re: Primary keepalive message not appearing in Logical StreamingReplication
Дата
Msg-id 20190915160129.otx5xajz7652ak73@development
обсуждение исходный текст
Ответ на Re: Primary keepalive message not appearing in Logical Streaming Replication  (Michael Loftis <mloftis@wgops.com>)
Список pgsql-hackers
On Sun, Sep 15, 2019 at 09:44:14AM -0600, Michael Loftis wrote:
>On Sun, Sep 15, 2019 at 08:36 Virendra Negi <viren.negi@teliax.com> wrote:
>
>> Oh I miss the documentation link there you go
>> https://www.postgresql.org/docs/9.5/protocol-replication.html
>>
>> On Sun, Sep 15, 2019 at 8:05 PM Virendra Negi <viren.negi@teliax.com>
>> wrote:
>>
>>> Agreed but why is there a message specification for it describe in the
>>> documentation  and it ask to client reply back if a particular *bit* is
>>> set.(1 means that the client should reply to this message as soon as
>>> possible, to avoid a timeout disconnect. 0 otherwise)
>>>
>>
>This is unrelated to TCP keepalive. I honestly don't know where the knob is
>to turn these on but the configuration variables you quoted earlier I am
>familiar with and they are not it. Perhaps someone else can chime in with
>how to enable the protocol level keepalive in replication.
>

Pretty sure it's wal_sender_timeout. Which by default is 60s, but if you
tune it down it should send keepalives more often.

See WalSndKeepaliveIfNecessary in [1]:

[1] https://github.com/postgres/postgres/blob/master/src/backend/replication/walsender.c#L3425

regards

-- 
Tomas Vondra                  http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services 



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

Предыдущее
От: Michael Loftis
Дата:
Сообщение: Re: Primary keepalive message not appearing in Logical Streaming Replication
Следующее
От: David Fetter
Дата:
Сообщение: Re: Efficient output for integer types