Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gyzLZ-0000I3-Hh for pgsql-admin@arkaria.postgresql.org; Wed, 27 Feb 2019 13:34:06 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gyzLY-0005A4-8Y for pgsql-admin@arkaria.postgresql.org; Wed, 27 Feb 2019 13:34:04 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gyzLX-00057Q-U8 for pgsql-admin@lists.postgresql.org; Wed, 27 Feb 2019 13:34:04 +0000 Received: from truschnigg.info ([89.163.150.210]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gyzLR-00014w-7q for pgsql-admin@lists.postgresql.org; Wed, 27 Feb 2019 13:34:03 +0000 Received: from vault.lan (84-112-34-152.cable.dynamic.surfer.at [84.112.34.152]) by truschnigg.info (Postfix) with ESMTPSA id 13F0920176; Wed, 27 Feb 2019 13:33:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=truschnigg.info; s=mail; t=1551274436; bh=KCg+FoAyQGqJzQP5Pb3Q/2epxSLyRZvaC/2LgoeGP6g=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Girm0JPixFvv0wAjL289h3dVttwRLYIPUUoup1DCnzX11fZDDf9Buhg0cA1dPJI4b LStLFuIEjqyXGqBf1bLPj1vPXchcoFe6hI731f83KwEBdjQFQuTog8s6kWrT5fFG+i uhq81xltSzz30Zi5/4rIriGf1aQrpoAv9JI/p+S8= Date: Wed, 27 Feb 2019 14:33:54 +0100 From: Johannes Truschnigg To: Achilleas Mantzios Cc: pgsql-admin@lists.postgresql.org Subject: Re: Logical replication and wal segment retention Message-ID: <20190227133350.rtmfaxyif43brugo@vault.lan> References: <695C083D-AFB5-431B-B022-ED442CE94794@gmail.com> <20190227125242.6ixy4jkzcuj55cdl@vault.lan> <59567e0a-78e4-ed1c-f5b1-033aafcfb68a@matrix.gatewaynet.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="z2dl46zeu3zq2osa" Content-Disposition: inline In-Reply-To: <59567e0a-78e4-ed1c-f5b1-033aafcfb68a@matrix.gatewaynet.com> User-Agent: NeoMutt/20170113 (1.7.2) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --z2dl46zeu3zq2osa Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Feb 27, 2019 at 02:57:46PM +0200, Achilleas Mantzios wrote: > > [...] > A logical approach for replication slots would be to accept a parameter > regarding max WAL files to retain, after which newer WALs will be removed > and the primary server saved.=A0 Pretty much like : --archive-push-queue-= max > argument of pgbackrest . Before replication slots where a thing, you had to carefully balance wal_keep_segments in regard to WAL production or/and (usually and :)) set u= p a proper WAL archive for replication to be able to soldier on even after a WAL receiver experienced service-interrupting trouble for a while. The benefit of that was that the WAL producer remained unaffected (unless y= ou bungled the archiving process profoundly) of such calamities. To me, that w= as the preferred trade-off for all use-cases of replication that I personally encountered. If it were possible to have the best of both worlds (i.e. have a kind of "h= igh water mark number of WAL segments"-setting per replication slot, over which the slot would be abandoned - with a heavy heart and lots of screaming in t= he logs, of course - by the producer), that sure would be awesome. But at this time, we are where we are :) --=20 with best regards: - Johannes Truschnigg ( johannes@truschnigg.info ) www: https://johannes.truschnigg.info/ phone: +43 650 2 133337 xmpp: johannes@truschnigg.info Please do not bother me with HTML-email or attachments. Thank you. --z2dl46zeu3zq2osa Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEGu9IhkI+7/aKLUWF95W3jMsYfLUFAlx2kboACgkQ95W3jMsY fLV/4A//Q9AhisWokcm6vlB0w9krqlpMpGtImfg47zlnoOxd3QG7QSEbz4Fwbpix 7OqudBwm1YlT8srDJ+yzNOnVENE547Yl0kftwj8/2peXOjf5GHcHJY3WG1p1Q3wp OlLIi8BIYpkAc44E6+PxJ2JyXt78uVAwNcoI2hkVGAxNF2zYaDkKdpqKnIHH8P59 0zBR2Xy6w5GSzb157zzr5bTkI7M8+OqKb5iAr8vt+3Qpr4e/SOJLNXIAzx4Td4RJ yP+099aZNCgKWimqFSsHwd4mdMW9QDTYnroIuB4tfOWDjXxUK0Cp0UBDH9011cMy rhHH8RZx9dBQJm4p2vpG2hi932GAoa2e6Ptk2yP7cHPGSR/T25JjD7WzFYLUsJwL NqTrMX0jmJgCUKTMpsXC3S8NLjCt8vXIBE6MTKl84wZEYT8P5eedYHmLKycsCIux gwqDpzkgfaJgdIA0is8MAGHBGSmjZJDpcD2pdr4VDOCE4tBox70Ki/X9DAB9LZo9 m+nhl79CZ3Wua2ZX2ltuYpnkX4a0jiPx6/R+0vD9lFrAhk2RPrj+6dk7IeTEIGUd Aevo0kiPKGKuRm4O28GGV7dbiA/JUFCcV6xOGewy1HSguh2TTQzaSbbzp1uS9+Hw vuZyMDM8ZG+Cd8/aXHTrS6N0SBag5JdTl9fb0D7NxflUYeyvNTU= =lSdU -----END PGP SIGNATURE----- --z2dl46zeu3zq2osa--