Re: max_wal_size and wal_keep_size

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

 



On Tue, 2022-08-30 at 08:29 +0000, James Pang (chaolpan) wrote:
> We want keep more wal to give more room for data replication, in case of some delay ,
> and need old wal data. So wan to set wal_keep_size , and want to increase
> max_wal-size a lot to make max_wal_size > wal_keep_size (it may > 1TB).

The two parameters are independent:
- "max_wal_size" does *not* determine the maximum WAL size, but how much
  WAL can be produced before the next checkpoint is triggered.
- "wal_keep_size" determines how much old WAL is kept around.

Set "wal_keep_size" and leave "max_wal_size" unchanged.

Or even better, use a replication slot.

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





[Index of Archives]     [Postgresql Home]     [Postgresql General]     [Postgresql Performance]     [Postgresql PHP]     [Postgresql Jobs]     [PHP Users]     [PHP Databases]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Yosemite Forum]

  Powered by Linux