Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lEomC-0003y8-Hs for pgsql-docs@arkaria.postgresql.org; Wed, 24 Feb 2021 07:40:05 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lEomB-0001t3-6q for pgsql-docs@arkaria.postgresql.org; Wed, 24 Feb 2021 07:40:03 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lEnbK-00025N-Rv for pgsql-docs@lists.postgresql.org; Wed, 24 Feb 2021 06:24:46 +0000 Received: from mx1.philphonic.de ([2a01:4f8:211:1e4b::2]) by magus.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lEnbH-0004Mc-0a for pgsql-docs@lists.postgresql.org; Wed, 24 Feb 2021 06:24:46 +0000 Subject: Re: incoorect restore_command DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=philphonic.de; s=2019; t=1614147880; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EHJO27ka2pM449umIosah/RCbllV9qv1xf6Gf0kAHUo=; b=QWUYiADRD+SRo/u8Bvg9uj5W9ubwsanPCRj0oTL0JVEa5UoACZFuhB4HV8qQrC+YexZsM4 PHIew+ehK97XCqHPnGl+5rS7+el6LiNYl1ub3gtoddGw0mwZEdKWNDLFRGD8VXPY4xk2J/ ENhwwVNGl4oDhc9jVfIBmtvvGO+XWATLUk97GlocHaet+Eu4tDbs+sqPLNpVuI6Fzmsrlr fRczALmxyYV6V7olo/NsPk44KrwwPWv9X8VJZrlYWdzNiVCrvfDFsWOfec6nmDeSQGSlcc 9MGPUnUaZaduzJVwXjzHIv+A3qZKVuYhX5mR5JjvX0Z0mJ9AP/4dgaKGesaaHA== To: Michael Paquier , pgsql-docs@lists.postgresql.org References: <161397938841.15451.13129264141285167267@wrigleys.postgresql.org> From: Philipp Gramzow Message-ID: <478b5b00-5ab3-a1b5-65f4-19b4409c720b@philphonic.de> Date: Wed, 24 Feb 2021 07:24:17 +0100 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Authentication-Results: ORIGINATING; auth=pass smtp.auth=phil@philphonic.de smtp.mailfrom=phil@philphonic.de List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Am 24.02.2021 um 06:49 schrieb Michael Paquier: > On Mon, Feb 22, 2021 at 07:36:28AM +0000, PG Doc comments form wrote: >> I've been trying out saving and restoring compressed archive logs. The >> restore_command stated in the docs at "25.3.6.2. Compressed Archive Logs" >> ('gunzip < /mnt/server/archivedir/%f > %p') did not work for me, because the >> archive_command ('gzip < %p > /var/lib/pgsql/archive/%f') alters the >> filename to %f.gz > On which platform please? Using a pipe with gzip does not alter the > output file name where the data is pushed to. We're on RHEL 7. Thanks for pointing out my mistake, someone altered our archive_command to use .gz extensions without me noticing it. Please excuse the confusion. >> I had to change the restore_command to 'gunzip < >> /mnt/server/archivedir/%f.gz > %p'. > Now, I kind of agree that compressing a file and not using a proper > .gz extension for its name can be confusing. So what about the > attached to tweak both archive_command and restore_command in this > section of the docs? > -- > Michael I agree, using a proper extension would be more straightforward. I'm sure that's the reason why someone changed our archive_command. Phil