Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bRhlB-0001ap-7Q for pgsql-bugs@arkaria.postgresql.org; Mon, 25 Jul 2016 15:25:37 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bRhlA-0006Ev-Fq for pgsql-bugs@arkaria.postgresql.org; Mon, 25 Jul 2016 15:25:36 +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_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bRhl9-0006E5-Ic for pgsql-bugs@postgresql.org; Mon, 25 Jul 2016 15:25:35 +0000 Received: from tamriel.snowman.net ([2001:4830:167b::11]) by magus.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bRhl6-00015s-7T for pgsql-bugs@postgresql.org; Mon, 25 Jul 2016 15:25:34 +0000 Received: by tamriel.snowman.net (Postfix, from userid 1000) id 5B77E5F796; Mon, 25 Jul 2016 11:25:31 -0400 (EDT) Date: Mon, 25 Jul 2016 11:25:31 -0400 From: Stephen Frost To: Michael Paquier Cc: Andrew Gierth , PostgreSQL mailing lists Subject: Re: BUG #14228: replication slot catalog_xmin not cleared on slot reuse Message-ID: <20160725152531.GY4028@tamriel.snowman.net> References: <20160705173502.1398.70934@wrigleys.postgresql.org> <87vb0ja0b5.fsf@news-spur.riddles.org.uk> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="O0i8ts1wQXc4Kolf" Content-Disposition: inline In-Reply-To: X-Editor: Vim http://www.vim.org/ X-Info: http://www.snowman.net X-Operating-System: Linux/3.13.0-91-generic (x86_64) X-Uptime: 11:24:30 up 16 days, 16:48, 7 users, load average: 0.17, 0.09, 0.06 User-Agent: Mutt/1.5.21 (2010-09-15) X-Pg-Spam-Score: -3.2 (---) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org --O0i8ts1wQXc4Kolf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Michael Paquier (michael.paquier@gmail.com) wrote: > On Wed, Jul 6, 2016 at 12:56 PM, Andrew Gierth > wrote: > >>>>>> "Michael" =3D=3D Michael Paquier write= s: > > > > >> When creating a physical replication slot, the catalog_xmin field of > > >> the new slot is not initialized. If the slot storage had previously > > >> been used for a logical slot, the old catalog_xmin will remain in > > >> place and interfere with vacuum. > > > > Michael> Good catch! The same applies to confirmed_flush_lsn, which is > > Michael> used only by logical decoding and should remain as NULL for > > Michael> physical slots. So I propose the patch attached to address > > Michael> both problems. > > > > What about slot->effective_catalog_xmin ? >=20 > Yes. I guess so, as well as the other candidate_* fields in the slot > to begin from a clean state. Seems like we should try to get this in before the next round of point releases...? Thanks! Stephen --O0i8ts1wQXc4Kolf Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCgAGBQJXli9qAAoJEO1sijiDR2RVLSoP/1sdY85clCagZ3I0RL3ZSZRw SNyioGSnMuEYFZqn9dLm1ugU2EVtz73DRY2dqyxy5yq7B2tUuySZPUaee9xu9pEX H6PH77VjErGhZNoy5V1gENPPJ54TUfu40MVv53g+girQAinLBSgK9IgKWrza5auc XiZcdwTt+6uoRpoe3jucIKKxW7cjgfkHFpPRvHkNVtJLJ86hrChM80SDvUPsfVc2 ZQO/JHSNq4aZ+6qImV+c54lmkyXdQASxWbTfNxXiTRHdY8axEvodTIjLM3uVtUSk MdH6e5RcSMKL4lUJeUFOfyjRAF1PU/d1INEMIEIheoIimyfhx6hq5kcMffIpjlgh Diz/2gRHekPoeSeLSd5Mf64pJ72o/EAy5GlxDh5FXSTZtGui4b+vd/0HtiClkvK8 y6uQp1U7oIkmBz+jMYVHS4LWJ7f8y8YRjEWrhdOWz4YY9yMS+32PXETrf36SlzyR VZyjkmEpDhu7MzU5VFWIvBhsS9hmIC4ILJdcemxcszwhabW07lPPxLq8hGoXzBLv qeqrb55iXe3RS7UbwJfRCnmuyIAOA0rhapp/dikYPQPCBlSOX5lH2frxDiVoCm97 kvu+yeFcJIHJruP7kR0ZOc+0JUKYn7Q1hTnzzRZmzBDuG0YFhGu7E/gwgdavwBhc zPuStXx4LeSM/NA7yXJ0 =7vJ5 -----END PGP SIGNATURE----- --O0i8ts1wQXc4Kolf--