PG 10 streaming replication pg_wal question

From: ghiureai <isabella(dot)ghiurea(at)nrc-cnrc(dot)gc(dot)ca>
To: pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: PG 10 streaming replication pg_wal question
Date: 2017-11-30 17:20:07
Message-ID: 5A203DC7.40509@nrc-cnrc.gc.ca
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Hi LIst,
I am testing PG10 streaming replication , with archiving off, I have
pg_wal on separate directory to monitor the growth , I had the slave
offline yesterday for more than 20h while I was restoring one of db
(60GB) with pg_restore from a backup taken with pg_dump, today I brought
the slave PG host online and replication catch up nicely , master and
slave are in sync now, but on master host the pg_wal is still same
large size ( as yesterday) even after all the wal files had been
applied to salve, would replication process not suppose to removed the
wal files on master after being applied to salve ?
( do I need to manually implement a cleanup job of this wal files, as
mentioned archiving is off on both servers)
see bellow:

master: pg_current_wal_lsn
--------------------
C5/D82DDD68

and slave: pg_last_wal_receive_lsn
-------------------------
C5/D82DDD68

and master :
4.0K ./wal/archive_status
166G ./wal
last wal file :
w------- 1 postgres postgres 16777216 Nov 29 16:05 00000007000000C5000000D8

ans slave :
12K ./wal/archive_status
1.1G ./wal

last wal file:
rw------- 1 postgres postgres 16777216 Nov 30 08:56 00000007000000C5000000D8

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Laurenz Albe 2017-11-30 17:35:21 Re: PG 10 streaming replication pg_wal question
Previous Message Alex Kliukin 2017-11-30 16:52:59 Re: 'replication checkpoint has wrong magic' on the newly cloned replicas