Do not delete files from pg_wal to solve a growing PostgreSQL disk. A persistent physical or logical replication slot tells PostgreSQL that a consumer may still need old write-ahead log records. If that consumer stops advancing, the primary can retain WAL from the slot's restart_lsn while ordinary ...