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 1ljNEa-0005YE-Fu for pgsql-docs@arkaria.postgresql.org; Wed, 19 May 2021 14:31:40 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ljNEZ-000622-Gh for pgsql-docs@arkaria.postgresql.org; Wed, 19 May 2021 14:31:39 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ljNEZ-00061u-A7 for pgsql-docs@lists.postgresql.org; Wed, 19 May 2021 14:31:39 +0000 Received: from tamriel.snowman.net ([70.109.60.50]) by makus.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ljNEX-0008CM-4R for pgsql-docs@lists.postgresql.org; Wed, 19 May 2021 14:31:38 +0000 Received: by tamriel.snowman.net (Postfix, from userid 1000) id BF2675F799; Wed, 19 May 2021 10:31:35 -0400 (EDT) Date: Wed, 19 May 2021 10:31:35 -0400 From: Stephen Frost To: Laurenz Albe Cc: pgsql-docs@lists.postgresql.org Subject: Re: Improve documentation for pg_upgrade, standbys and rsync Message-ID: <20210519143135.GI20766@tamriel.snowman.net> References: <22f129004bb66cd91e1dfd3345a9787f5039f3ae.camel@cybertec.at> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="gQuU0/gWFJsU7sPc" Content-Disposition: inline In-Reply-To: <22f129004bb66cd91e1dfd3345a9787f5039f3ae.camel@cybertec.at> User-Agent: Mutt/1.5.24 (2015-08-30) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --gQuU0/gWFJsU7sPc Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Greetings, * Laurenz Albe (laurenz.albe@cybertec.at) wrote: > I revently tried to upgrade a standby following the documentation, > but I found it hard to understand, and it took me several tries to > get it right. This is of course owing to my lack of expertise with > rsync, but I think the documentation and examples could be clearer. >=20 > I think it would be a good idea to recommend the --relative option > of rsync. >=20 > Here is a patch that does that, as well as update the versions in > the code samples to something more recent. Also, I think it makes > sense to place the data directory in the sample in /var/lib/postgresql, > which is similar to what many people will have in real life. Haven't had a chance to look at this in depth but improving things here would be good. An additional thing that we should really be mentioning is to tell people to go in and TRUNCATE all of their UNLOGGED tables before going through this process, otherwise the rsync will end up spending a bunch of time copying the files for UNLOGGED relations which you really don't want. Thanks, Stephen --gQuU0/gWFJsU7sPc Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCgAGBQJgpSFHAAoJEO1sijiDR2RVTLEP/jwG8cAZJka+V7gT3nNynBCv ES6yJppE6/U49ZYonoglmHgIRh0u0xp/OduFPKp4nXtsuWcgbl/8LQSc196H/WHB glad1KTRwCmXADO5ubXdTZsYulgUm/9brjohKQIZO/DLnf4ATozUsnRYCLsbjbbJ dOJkRKKxDhji82C3lgQKHyj/r2+3SdVeoVfZTyr0sPrsWUtvKx03/VZ+s9mzogkR r0Bno/JqTFWwbY+bP/DmPRDrP+SdEe7ZW8URsEoKkpqamDsLcWzkAXi6DF0iau0o 95SazcI1t+8IhiRemY+l9gT9yv4E84Pes33mbGe0yatpxewJfVguab8pVRztr+pq cUsMBhnPSjQc7NDL8E8IgmNRFP4bI1b9UaByWgsJiiaqsNiCinWJ+uovArpQchmt U9X+nd44i08CdiY8AO49cxclhIJrWLYRZLr2rgtV82FyumrAbZBxEHJBXqEBcVki qQzWU4YvGimX0+v5g0gETLnxDAM0en++ujYlvM61Gb3gfVrFenuv3eltL/D4khmW DAsqwyybF0OJEo2Z/oEPgOVngcFdeDRuCHDCK8Vue3ndO+vHZ+HPx7of+JuKBqMb UuHRN34kF/4Ge+aOOLV1+Ge61G1qf+Va3cI/Sbj2zcQlDV8/s/39k8jr1Ysd7pto 5gSp76Mp6cWhayEQ78PP =snYr -----END PGP SIGNATURE----- --gQuU0/gWFJsU7sPc--