Re: logical replication, with a replication slot but still getting "requested WAL segment has already been removed" - Mailing list pgsql-admin

From Laurenz Albe
Subject Re: logical replication, with a replication slot but still getting "requested WAL segment has already been removed"
Date
Msg-id d84d9729b07ae61edc66ee58c2c413f0b8ecc37b.camel@cybertec.at
Whole thread Raw
In response to logical replication, with a replication slot but still getting "requested WAL segment has already been removed"  (Sbob <sbob@quadratum-braccas.com>)
List pgsql-admin
On Mon, 2025-12-22 at 14:14 -0700, Sbob wrote:
> We have setup logical replication for some very large tables, both publisher and subscriber
> are running postgresql v14, however even though the locical replication is using a replication
> slot we keep getting this error:
>
>  2025-12-21 23:25:50.452 UTC [2131314] LOG:  logical replication apply worker for subscription "bigtables_sub" has
started
>  2025-12-21 23:25:50.987 UTC [2131314] ERROR:  could not receive data from WAL stream: ERROR:  requested WAL segment
000000020000089F00000098has already been removed 

Look into "pg_replication_slots" on the publisher, perhaps the "wal_status" has changed
to "unreserved" or "lost".  One possible cause for that could be the setting of
"max_slot_wal_keep_size" on the publisher.

Yours,
Laurenz Albe



pgsql-admin by date:

Previous
From: Sbob
Date:
Subject: logical replication, with a replication slot but still getting "requested WAL segment has already been removed"