Streaming replication doesn't restart after timeout - Mailing list pgsql-bugs

From Kurt Roeckx
Subject Streaming replication doesn't restart after timeout
Date
Msg-id 20200312085805.GA3811492@roeckx.be
Whole thread Raw
Responses Re: Streaming replication doesn't restart after timeout  (Sergei Kornilov <sk@zsrv.org>)
List pgsql-bugs
Hi,

I've just set up streaming replication, and the walreceiver got a
timeout and doesn't seem to start again.

This is the log on the slave:
2020-03-10 14:22:44.459 CET [9075] LOG:  entering standby mode
2020-03-10 14:22:44.768 CET [9075] LOG:  redo starts at 21C/25B67338
2020-03-11 04:54:24.365 CET [9075] LOG:  consistent recovery state reached at 237/7114CF60
2020-03-11 04:54:24.375 CET [7974] LOG:  database system is ready to accept read only connections
2020-03-11 04:54:26.136 CET [3776] LOG:  started streaming WAL from primary at 237/72000000 on timeline 1
2020-03-12 05:03:00.965 CET [3776] FATAL:  terminating walreceiver due to timeout

This is on the server side:
2020-03-12 05:02:58.099 CET [19433] replication@[unknown] LOG:  terminating walsender process due to replication
timeout

The last few wal files on the slave are:
-rw------- 1 postgres postgres 16777216 Mar 12 05:01 0000000100000287000000E5
-rw------- 1 postgres postgres 16777216 Mar 12 05:01 0000000100000287000000E6
-rw------- 1 postgres postgres 16777216 Mar 12 05:01 0000000100000287000000E7
-rw------- 1 postgres postgres 16777216 Mar 12 05:01 0000000100000287000000E8
-rw------- 1 postgres postgres 16777216 Mar 12 05:01 0000000100000287000000E9
-rw------- 1 postgres postgres 16777216 Mar 12 05:01 0000000100000287000000EA
-rw------- 1 postgres postgres 16777216 Mar 12 05:01 0000000100000287000000EB
-rw------- 1 postgres postgres 16777216 Mar 12 05:01 0000000100000287000000EC
-rw------- 1 postgres postgres 16777216 Mar 12 05:02 0000000100000287000000ED

The slave has not catched up with the master yet.

During the initial recovery it also didn't download any wal files.
It just processed the wal files pg_basebackup downloaded during
the backup. So between 2020-03-10 14:22:44 and 2020-03-11 04:54:24
it didn't download any wal files.

It's still not finished processing the wal files it has received.
Is it only going to start downloading new wal files once it has
processed all the previous wal files it downloaded? I was
expecting it to restart.


Kurt




pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: Postgresql create a core while trying log a message to syslog
Next
From: Sergei Kornilov
Date:
Subject: Re: Streaming replication doesn't restart after timeout