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 1kQNJZ-0004x1-BS for pgsql-docs@arkaria.postgresql.org; Thu, 08 Oct 2020 04:14:01 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kQNJX-0007xC-2r for pgsql-docs@arkaria.postgresql.org; Thu, 08 Oct 2020 04:13:59 +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 1kQNJW-0007w5-Tv for pgsql-docs@lists.postgresql.org; Thu, 08 Oct 2020 04:13:58 +0000 Received: from oss.nttdata.com ([49.212.34.109]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kQNJT-0001gQ-IK for pgsql-docs@postgresql.org; Thu, 08 Oct 2020 04:13:57 +0000 Received: from hnk.local (p1295030-ipngn4902funabasi.chiba.ocn.ne.jp [153.166.85.30]) by oss.nttdata.com (Postfix) with ESMTPSA id 54A5A623FD; Thu, 8 Oct 2020 13:13:52 +0900 (JST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.102.3 at oss.nttdata.com Subject: Re: doc bug for continuous archiving To: Jeff Janes , "David G. Johnston" Cc: pgsql-docs References: From: Fujii Masao Message-ID: <7c17abbf-4fcf-e8c8-643f-cb33667f33e4@oss.nttdata.com> Date: Thu, 8 Oct 2020 13:13:52 +0900 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:68.0) Gecko/20100101 Thunderbird/68.12.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2020/10/08 7:12, Jeff Janes wrote: > On Wed, Oct 7, 2020 at 5:47 PM David G. Johnston > wrote: > > On Wed, Oct 7, 2020 at 2:35 PM Jeff Janes > wrote: > > Quoting the docs: > > https://www.postgresql.org/docs/13/continuous-archiving.html > > "As with base backups, the easiest way to produce a standalone hot backup is to use the pg_basebackup tool. If you include the -X parameter when calling it, all the write-ahead log required to use the backup will be included in the backup automatically, and no special action is required to restore the backup." > > This makes it sound like -X is a switch option, when in fact it demands an argument.  The statement made is incorrect if the supplied argument is "none", but  is correct for the other two options.  Should this be changed to spell out which options it applies to (or maybe which option it does not apply to). > > > Just reading the doc page for pg_basebackup: "stream" is the default method value for this option.  So if you just include "-X" you get "stream" which is indeed a mode that just works and the continuous archiving section you quote is correct. > > I'm not really sure I like the idea that we don't indicate which pg_basebackup key-value argument values are optional and which are mandatory. > > David J. > > Stream is the default if you don't specify -X at all. We should use the description like "Unless -X none is specified when calling it" ? >  If you specify -X but with no argument for it, you get an error. > > pg_basebackup: option requires an argument -- 'X' > Try "pg_basebackup --help" for more information. > > (Which is also a bit confusing, I would expect a default to apply when the option is specified without an argument, as opposed to when the option itself it is not specified ) As far as I recall, we discussed that in [1] and gave up doing that. Regards, [1] https://postgr.es/m/1338235863.24935.27.camel@vanquo.pezone.net -- Fujii Masao Advanced Computing Technology Center Research and Development Headquarters NTT DATA CORPORATION