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 1jnKCW-0000tE-G6 for pgsql-general@arkaria.postgresql.org; Mon, 22 Jun 2020 11:01:20 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jnKCV-0003qU-Dk for pgsql-general@arkaria.postgresql.org; Mon, 22 Jun 2020 11:01:19 +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 1jnKCV-0003qN-63 for pgsql-general@lists.postgresql.org; Mon, 22 Jun 2020 11:01:19 +0000 Received: from mail.hjp.at ([212.17.106.138] helo=rorschach.hjp.at) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jnKCS-0007c2-A0 for pgsql-general@lists.postgresql.org; Mon, 22 Jun 2020 11:01:18 +0000 Received: by rorschach.hjp.at (Postfix, from userid 1000) id 564EA32DF; Mon, 22 Jun 2020 13:01:13 +0200 (CEST) Date: Mon, 22 Jun 2020 13:01:13 +0200 From: "Peter J. Holzer" To: pgsql-general@lists.postgresql.org Subject: Re: Netapp SnapCenter Message-ID: <20200622110113.GA5340@hjp.at> References: <2C6D03C3-CFF0-4F14-BA83-A2809BA29196@gmail.com> <20200618192642.GH6680@tamriel.snowman.net> <20200619160248.GI6680@tamriel.snowman.net> <064CCB04-4279-48F1-AF1A-1C3036843350@gmail.com> <20200622053610.GB3125@tamriel.snowman.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="T4sUOijqQbZv57TR" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --T4sUOijqQbZv57TR Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2020-06-22 08:02:06 +0200, Paul F=F6rster wrote: > > On 22. Jun, 2020, at 07:36, Stephen Frost wrote: > > The thing about this is though that the new API avoids *other* issues, > > like what happens if the system crashes during a backup (which is an > > entirely common thing that happens, considering how long many backups > > take...) and it does so in a relatively reasonable way while also > > allowing concurrent backups, which is perhaps a relatively modest > > benefit but isn't the main point of the different API. >=20 > that makes me curious about another thing. The output of > pg_stop_backup() is to be stored. Otherwise the backup is useless. So > far, so good. But what if the server crashes in the middle of the > backup and pg_stop_back() hence is never reached? In this case, it > obviously does not create any output. Correct. Your backup will also almost certainly be missing some files, so it won't be usable anyway. > Ok, you usually start the server, the database does a crash recovery > and opens. Then, some time later, you do the usual backup and all is > well. This is like 99.999% of all cases. >=20 > But what if you need to restore to the latest transaction while the > database was running in backup mode during which the crash occurred. > How does that work if no pg_stop_backup() output exists? Did I miss > something here? Restore the previous backup and replay WALs from there (that assumes of course that you are archiving WALs continuously, but if you don't, you can't do PITR in general, so if you have that requirement you are doing it). hp --=20 _ | Peter J. Holzer | Story must make more sense than reality. |_|_) | | | | | hjp@hjp.at | -- Charles Stross, "Creative writing __/ | http://www.hjp.at/ | challenge!" --T4sUOijqQbZv57TR Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEETtJbRjyPwVTYGJ5k8g5IURL+KF0FAl7wj3QACgkQ8g5IURL+ KF1gng//WGnsmriutOMcbikV4MSDGx9svDxYArfuS6fv7DmPkOLxOLzsjERg7bXC N9byGwNdOcBHx2k1QhC/jAexwe58+LX6WI3KjQbPONBDJbjDoAxkZACqrR6XPUmA 7IrdJb9bmja0yS3GyQ3aUI9z2QSHD863JCtDhGV7vM4713M7TzKyQ9l2KvRQpoJa UlA+yN5E6UHP+uIHkSw8zmtrMIByaqzmM5hu8y+iLf1g0Ayh+uYrurAGNBu1ivEc 5w3Y4giHOdxZK/z1BOM7biT+KExllMnnKf5SSAjVImDqgFqooIBO7y/TcKSE6UbC 6FLNtAm67TGqHsr78IV0eh5sTY2Ot3VtuWkG9oMpDReI5kUvXb2SY2SJ/FWiSigB xTsGThJTS4qzkE3wKVFpY9rBtXbVYV9zXh+giQq0/gWXAqWYqY7OAZWu2z9i8fHh m59CbIlBzLSviJSLNjFHnZr8XC0RvNrT2t6o7kUWDfj1Ewv3lxNnPZrDPPqs651p ULVMLSYko1jYC/ulhRJ6NobMNhBBYCRTnZp3m0cYP/0mr6+01jlrvbCLRBuPOn86 Dlt2lyNxOQtCwpUveZ7xMB6bhIH1gn5qPAyacCzAF5oqRp2LAk8YGsI52PCw4taC s47zvhZKh0MhAn2LOoWyhxOlqjJI3BAOcl1m0zCIGn4jJBVynJk= =vwCh -----END PGP SIGNATURE----- --T4sUOijqQbZv57TR--