1
0
mirror of https://github.com/postgres/postgres.git synced 2025-12-24 06:01:07 +03:00

pg_resetwal: Allow users to change the WAL segment size

This adds a new option --wal-segsize (analogous to initdb) that changes
the WAL segment size in pg_control.

Author: Nathan Bossart <bossartn@amazon.com>
This commit is contained in:
Peter Eisentraut
2018-03-25 14:58:49 -04:00
parent 8ad8d916f9
commit bf4a8676c3
2 changed files with 65 additions and 9 deletions

View File

@@ -275,6 +275,28 @@ PostgreSQL documentation
</listitem>
</varlistentry>
<varlistentry>
<term><option>--wal-segsize=<replaceable class="parameter">wal_segment_size</replaceable></option></term>
<listitem>
<para>
Set the new WAL segment size, in megabytes. The value must be set to a
power of 2 between 1 and 1024 (megabytes). See the same option of <xref
linkend="app-initdb"/> for more information.
</para>
<note>
<para>
While <command>pg_resetwal</command> will set the WAL starting address
beyond the latest existing WAL segment file, some segment size changes
can cause previous WAL file names to be reused. It is recommended to
use <option>-l</option> together with this option to manually set the
WAL starting address if WAL file name overlap will cause problems with
your archiving strategy.
</para>
</note>
</listitem>
</varlistentry>
<varlistentry>
<term><option>-x <replaceable class="parameter">xid</replaceable></option></term>
<term><option>--next-transaction-id=<replaceable class="parameter">xid</replaceable></option></term>