From: p.luzanov@postgrespro.ru
To: David G. Johnston <david.g.johnston@gmail.com>
Cc: pluzanov@postgrespro.ru
Cc: pgsql-docs@lists.postgresql.org
Subject: Re: max_wal_size
Date: Wed, 27 May 2020 19:17:23 +0300
Message-ID: <92491c6d07a3216ef2caee8ef55c02b5@postgrespro.ru> (raw)
In-Reply-To: <CAKFQuwZOwfUwOxNh5KjUjCSFaecUWxtHEbPHEK8CJF1+zn9Bjg@mail.gmail.com>
References: <159057129673.7025.17016799863173731176@wrigleys.postgresql.org>
<CAKFQuwZOwfUwOxNh5KjUjCSFaecUWxtHEbPHEK8CJF1+zn9Bjg@mail.gmail.com>
David,
> This setting is the indirect means to ensure that the WAL directory
> doesn't get too large by forcing a checkpoint thus allowing the
> corresponding WAL to be removed.
This is a soft limit, ok.
But the question is a little different.
Suppose we have: version >= 11, no replication slots, archive_mode =
off.
Checkpoint_timeout is big enough, so checkpoints triggered only by
max_wal_size (1GB).
checkpoint_completion_target = 1.
What size of WAL files will be generated between checkpoints?
1GB or 0.5GB?
As I understand the description of max_wal_size(Maximum size to let the
WAL grow to between automatic WAL checkpoints), the answer is 1GB.
But it seems that the right answer is 0.5GB.
-----
Pavel Luzanov
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-docs@postgresql.org
Cc: p.luzanov@postgrespro.ru, david.g.johnston@gmail.com, pluzanov@postgrespro.ru, pgsql-docs@lists.postgresql.org
Subject: Re: max_wal_size
In-Reply-To: <92491c6d07a3216ef2caee8ef55c02b5@postgrespro.ru>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox