From: Michael Paquier <michael@paquier.xyz>
To: Adrian Klaver <adrian.klaver@aklaver.com>
Cc: Andrus <kobruleht2@hot.ee>
Cc: pgsql-general <pgsql-general@postgresql.org>
Subject: Re: How to recover from compressed wal archieve in windows
Date: Thu, 21 May 2020 10:27:38 +0900
Message-ID: <20200521012738.GI2355@paquier.xyz> (raw)
In-Reply-To: <aa6d4399-1b99-5b32-0fa8-67abe195beb3@aklaver.com>
References: <241F4C06123741D8BA0283C8690A5F12@dell2>
<aa6d4399-1b99-5b32-0fa8-67abe195beb3@aklaver.com>
On Wed, May 20, 2020 at 11:36:09AM -0700, Adrian Klaver wrote:
> The next problem is that I'm pretty sure a WAL file with *.gz extension will
> not be able to be processed directly by the server. So you are going to have
> to uncompress it at some point before it gets restored.
The short answer to that question is no. The backend does not
uncompress the segment file. What happens is that the restore command
copies the file defined by %f to the location of %p where is gets
renamed to RECOVERYXLOG, and we expect the restore command to drop a
16MB file in og_wal/. There is a check on the size, which would fail
if the WAL segment is still compressed. This logic is in
RestoreArchivedFile() in xlogarchive.c.
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
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-general@postgresql.org
Cc: michael@paquier.xyz, adrian.klaver@aklaver.com, kobruleht2@hot.ee
Subject: Re: How to recover from compressed wal archieve in windows
In-Reply-To: <20200521012738.GI2355@paquier.xyz>
References: <241F4C06123741D8BA0283C8690A5F12@dell2> <aa6d4399-1b99-5b32-0fa8-67abe195beb3@aklaver.com> <20200521012738.GI2355@paquier.xyz>
* 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