AWS Posgres RDS disk space consumption in idle database when using logical replication

0

When logical replication is enabled in AWS Posgres RDS, and DMS is used to replicate the changes, replication slot gets created for that. DMS replication is only after 4 tables, and in lower environment, there are not much changes in these tables, database could be idle for a long time.

What is happening is, when database is idle, replication slot cursor doesn't move and causes WAl files to be retained. However, new wal files ~64MB is getting added every 5 mins - due to some periodic background process in rdsadmin. This leds to posgres RDS Free disk space constantly reducing at at rate of 64MB every 5 mins.

Space is retained where there are changes in the tables subscribed by DMS, as the replication slot cursor moves, but in lower environment change frequency are quite low.

Posgres RDS is an upstream system managed by another team, i'm just consuming the data for downstream application. logical replication is causing increased disk space consumption during idle time, and this has been raised as an concern.

Could anyone suggest whats the best way to handle this. Is there a possibility of reducing the frequency of the periodic background process at posgres side or decreased the memory foot print that can be suggested to posgres team. Or is there a good way to cause replication slot cursor to move ahead from consumption ( DMS ) end when no data is captured.

refraining from below option as it will require implanting an extra process in posgres end

  • create a table -> having a process that constantly upserts - subscribing to this table as well - in DMS.

Any suggestions would be greatly appreciated.

bipinns
asked 2 months ago447 views
1 Answer
0

Wal heartbeat feature should help in your case. please refer to https://repost.aws/knowledge-center/dms-high-storage-consumption-postgresql

AWS
answered 2 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions