Search Postgresql Archives

Re: Need help on understanding of wal_keep-segments and max_wal_size dependency.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2021-03-15 at 10:00 +0000, Swati yadav wrote:
> We are using streaming replication without  feature archiving and replication slots.
>
> Could you please help us in understanding how replication will works
> when I set max_wal_size to 1GB, wal_keep_segments  set to 300.
> 
> In this scenario, replication is getting failed.  Could you please brief
>  us the causes of failure and how can we fix this issue, apart from using
>  the feature archiving and replication slots.

"wal_keep_size" is irrelevant to the question.

"wal_keep_segments = 300" makes PostgreSQL keep 300 old WAL segments around
so that standby servers can catch up after a bit of downtime.

If, however, the downtime is long enough that the standby needs WAL that
is in an even earlier WAL segment that has already been archived and deleted,
the standby won't be able to catch up any more.

If you don't want to use "restore_command" or replication slots, your
only option is to increase "wal_keep_segments".

Yours,
Laurenz Albe
-- 
Cybertec | https://www.cybertec-postgresql.com






[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux