From: Michael Paquier <michael@paquier.xyz>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Add option --config-file to pg_rewind
Date: Wed, 06 Apr 2022 23:52:51 +0000
Message-ID: <E1ncFSE-000eOi-Ss@gemulon.postgresql.org> (raw)
Add option --config-file to pg_rewind
This option is useful to do a rewind with the server configuration file
(aka postgresql.conf) located outside the data directory, which is
something that some Linux distributions and some HA tools like to rely
on. As a result, this can simplify the logic around a rewind by
avoiding the copy of such files before running pg_rewind.
This option affects pg_rewind when it internally starts the target
cluster with some "postgres" commands, adding -c config_file=FILE to the
command strings generated, when:
- retrieving a restore_command using a "postgres -C" command for
-c/--restore-target-wal.
- forcing crash recovery once to get the cluster into a clean shutdown
state.
Author: Gunnar "Nick" Bluth
Reviewed-by: Michael Banck, Alexander Kukushkin, Michael Paquier,
Alexander Alekseev
Discussion: https://postgr.es/m/7c59265d-ac50-b0aa-ca1e-65e8bd27642a@pro-open.de
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/0d5c387573be5c40bf18b7b8983f406637dff42f
Modified Files
--------------
doc/src/sgml/ref/pg_rewind.sgml | 15 +++++++++++++++
src/bin/pg_rewind/pg_rewind.c | 22 ++++++++++++++++++++++
src/bin/pg_rewind/t/RewindTest.pm | 14 ++++++++++----
3 files changed, 47 insertions(+), 4 deletions(-)
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: michael@paquier.xyz
Subject: Re: pgsql: Add option --config-file to pg_rewind
In-Reply-To: <E1ncFSE-000eOi-Ss@gemulon.postgresql.org>
References: <E1ncFSE-000eOi-Ss@gemulon.postgresql.org>
* 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