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.92) (envelope-from ) id 1j7Dei-0004Bo-7s for pgsql-hackers@arkaria.postgresql.org; Thu, 27 Feb 2020 07:32:24 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1j7Def-00028N-7R for pgsql-hackers@arkaria.postgresql.org; Thu, 27 Feb 2020 07:32:21 +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 1j7Dee-00028G-UQ for pgsql-hackers@lists.postgresql.org; Thu, 27 Feb 2020 07:32:20 +0000 Received: from out2-smtp.messagingengine.com ([66.111.4.26]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1j7Dec-00010h-SN for pgsql-hackers@postgresql.org; Thu, 27 Feb 2020 07:32:19 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id 3B08321C1B; Thu, 27 Feb 2020 02:32:17 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Thu, 27 Feb 2020 02:32:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm1; bh=3y6gxt9f/+N6ctf2Li1F75+TPlv JorqSqeSdH3l/ERY=; b=Mb5miCUsgZmY2NJ1SuwAPn0aZ7fqSkJY25T8f5O1xbF 7CmnEpJRf+Sk49u62cclVFh1wuivDF9SfKSw79uvPMyCx5GZJN6laNBxzT/pIBey tsLYu1uj+ShVqHx3NTBTh5fSD87acaxzPczJjiHLE7COF1SNKiSAuKG53Bi6TdTT P+04Uc74KtO68CvJyUAkpIBh9N4X3sbIq/gyCHRhac6lcGWYSdCnSgO08MX7J/jR RdpAVN7SL5LbrcuN3bKejN2NWco8z9nvd8yKP0LBtoNT5V/jW9FnVmh5YaL+Xhzd YvpNoKgv/Xy/rhPz2MQQ0RpGgb3xCB3poKE/DHWcAFg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=3y6gxt 9f/+N6ctf2Li1F75+TPlvJorqSqeSdH3l/ERY=; b=D09GLdclK0VOkK/+xTMeAs iEQXtJ7pt7knOYsKcjb3BbHW9qal7gd4AaHMNApajVIa5Ead3c2fbAtk4femxMQc UF3QU/QzdiUJzCSnC1ad3Tv53Vq40ElzwKLqLjYBj/CG80vNv40bzmLR58GbB/ZV bRf7QN8owjJJWiy/PkneIyxXKJXN9D+jbK3sSMUEvl9Z+7vxSPTIwK3winvmLmq8 t8JHMwG5pXIRSqfvzuJG6nCllYLfxYv95f6np+amqk/uq8fMaOklz6GWRh8e2tsN iTeG5dddJW7jPNkfAWZiwqYkH+/1usIA5LInoBngAb2nlReeZ7gjLD41YT2eS8qQ == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrleehgdduudefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne gfrhhlucfvnfffucdljedtmdenucfjughrpeffhffvuffkfhggtggujgesghdtreertddt vdenucfhrhhomhepofhitghhrggvlhcurfgrqhhuihgvrhcuoehmihgthhgrvghlsehprg hquhhivghrrdighiiiqeenucfkphepuddukedrvdeguddrvdehuddrudekvdenucevlhhu shhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehmihgthhgrvghlse hprghquhhivghrrdighiii X-ME-Proxy: Received: from paquier.xyz (mp76f1fbb6.ap.nuro.jp [118.241.251.182]) by mail.messagingengine.com (Postfix) with ESMTPA id 075533060FCB; Thu, 27 Feb 2020 02:32:13 -0500 (EST) Date: Thu, 27 Feb 2020 16:32:11 +0900 From: Michael Paquier To: Julien Rouhaud Cc: Justin Pryzby , Sergei Kornilov , Peter Eisentraut , Michael Paquier , Andreas Karlsson , pgsql-hackers Subject: Re: reindex concurrently and two toast indexes Message-ID: <20200227073211.GA403330@paquier.xyz> References: <20200216190835.GA21832@telsasoft.com> <20200218052933.GH4176@paquier.xyz> <20200218061913.GJ4176@paquier.xyz> <20200222070924.GA57285@nol> <20200222150657.GA54846@nol> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="0F1p//8PRICkK4MW" Content-Disposition: inline In-Reply-To: <20200222150657.GA54846@nol> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --0F1p//8PRICkK4MW Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sat, Feb 22, 2020 at 04:06:57PM +0100, Julien Rouhaud wrote: > Sorry, I just realized that I forgot to commit the last changes before sending > the patch, so here's the correct v2. Thanks for the patch. > + if (skipit) > + { > + ereport(NOTICE, > + (errmsg("skipping invalid index \"%s.%s\"", > + get_namespace_name(get_rel_namespace(indexOid)), > + get_rel_name(indexOid)))); ReindexRelationConcurrently() issues a WARNING when bumping on an invalid index, shouldn't the same log level be used? Even with this patch, it is possible to reindex an invalid toast index with REINDEX INDEX (with and without CONCURRENTLY), which is the problem I mentioned upthread (Er, actually only for the non-concurrent case as told about reindex_index). Shouldn't both cases be prevented as well with an ERROR? -- Michael --0F1p//8PRICkK4MW Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAl5XcHsACgkQnvQgOdby QH3cIhAAilpjdskbXGn2ifgkPZMhBlDX6VVH4gMQWFusJhmLH9mj/Ku/MC0cvLoH 7Azt6hI0liK79qEU7qbsil9grDda9spYMWTgXuWmz+C63NktfD3oGknAmwlDmqWV BABUxRzXPqmuS5H/rc1azliBazX0IexEZRAeYjcKWH8PagwGS90hw44KnpnkQaYW coXqjOiLvW2+KC0pxmQOTkVev3v8mWCIB48ku/9rywVbWwqygWaL8g3hbY8Turmw 6UwaVEhnqOU4itT/xeyyBgO8YQ/H79+iO/5IC8hdefkkSsYOqhmA+NJAfqR30ekT A6aYnsBuA2Hgo3ucfp0v8e9FiKHsL1o21LLv8J62fiRDq0IhGf/JsyqCDY9xEgIZ OIQC5vd7ZgJ/nlFqWEIqZu0g3I3zi7Tl1DQPyIcDPddzZD7XDpO9I9veXSCsfHiW M/e2COnURiCirGfs8jKPf1tZwfPb3AN8Sg/VU3K1r7TU5c3ZCno2AotVS2qGvGnY WklQBJMQ+2Xd+WjFaB/OYo7lVJsWe5Z/M5oK6MJiW6o/pPJFvh3//aNOzFTexwLh RW37T0gZfpRNuQmg4bciRhiCkvleT5L8Vo7TGHdfhLp82yBALtFRCK5GUmszCrOP 9VvRFEP1d8BH/yrvgtW48Nq6zcm7mafnTTYdQbKCuy6n7Oklt2I= =M31b -----END PGP SIGNATURE----- --0F1p//8PRICkK4MW--