Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1xLTmM-00000001XJl-2uUA for pgsql-hackers@arkaria.postgresql.org; Mon, 26 Oct 2026 23:06:59 +0000 Received: from localhost ([127.0.0.1]:48288 helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.98.2) (envelope-from ) id 1xLTmL-00000008IdN-3QKL for pgsql-hackers@arkaria.postgresql.org; Mon, 26 Oct 2026 23:06:57 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]:60810) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1xLTmL-00000008IdF-1h6M for pgsql-hackers@lists.postgresql.org; Mon, 26 Oct 2026 23:06:57 +0000 Received: from fhigh-b6-smtp.messagingengine.com ([202.12.124.157]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1xLTmI-000000015mk-41mX for pgsql-hackers@postgresql.org; Mon, 26 Oct 2026 23:06:56 +0000 Received: from phl-compute-02.internal (phl-compute-02.internal [10.202.2.42]) by mailfhigh.stl.internal (Postfix) with ESMTP id 4127D7A03CC for ; Mon, 26 Oct 2026 19:06:54 -0400 (EDT) Received: from phl-frontend-04 ([10.202.2.163]) by phl-compute-02.internal (MEProxy); Mon, 26 Oct 2026 19:06:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm2; t=1793056013; x=1793142413; bh=wLPSqycURx cREz5pWnpfPzAIRJUnRpJuQ12noG6hrI4=; b=JgJecsDdbp79Gepj5pMkLrNTJF 6E2EDn2tStMhKsyTTHBpf2F+s5HBtbV05/PXhJdzxLOz7eYDs8hAX/DCHabzIumq e9W5OEx999jvgf44DZfTo/pjgbMctSZGqtWf1JYLDo/Eu3CYZnn9wM6oQfrvSXIt BTWBAT3mtTqKP6JJSLIvvapwUfnEbIwfe/43g7ge5fuuBpPHxDxM+xilG54GF228 hJQ40OC1MQv7YKM8DMJWGWdjWNZ8pdImcJPWxXmJnmwzXSVHbj4VD6ijSU1GIS6T Qp9s/0jqBaCgAtaNk6HZecjxU9o4qvedzjmnbZzo7CD5o4+GZPoh5/2zqf6g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t= 1793056013; x=1793142413; bh=wLPSqycURxcREz5pWnpfPzAIRJUnRpJuQ12 noG6hrI4=; b=XnxFzDxC+01h8ObUpMo3P4ccu7Y/bpFZLgDsttOGvxkzWit/QUp x0JCssdp+/zKPDuz5CaQvOsGnndQCOYfQA8Lo83puu2t+w2ZEj+36qwLeAkP0a5y 5UmsiKJhT5MVODS7+n0cUzjRjXMoJXO51cvbvysCE4vnhGnWe7IPxpUuhzuYjQGi V66ZLf1KXIjMrkPl+2raeU9lpYzGRrAMuH9XG0XDuiWuZJI90X35VV19jLhBMykO 6nJy28O5Wyq5DItFPRgoyqwppBq7wYKSuoyYWIt7gqqAMN0UIFKpaUGWKsiCdKlJ awDz5OF6VQIoL3FkGzwolC5rs/d8RBkRkYg== X-DKIM2-Info: draft=ietf-dkim-dkim2-spec-07; repo=github.com/dkim2wg/interop; date=2026-10-18; sw=lmtpprox; action=sign d=paquier.xyz a=rsa-sha256; DKIM2-Signature: i=1; m=1; t=1793056013; d=paquier.xyz; mf=PG1pY2hhZWxAcGFxdWllci54eXo+; rt=PHBnc3FsLWhhY2tlcnNAcG9zdGdyZXNxbC5vcmc+; s=fm2:rsa-sha256:do71VVkWzDELfaJSWdLFqZRQFO3LC59w8Nzmmk6atZshIFR qYPODNO4Mwe7Vlrq6yRTCqhdzX5G5HY+Yc6WXKouPB+jc1K3Zu8soVWznHrxL4bk mLZ00uIHAooRtr2fNeQrfSBDP2qegn+cEqTSbXBLh3KDe27RUh2MCUJ8FjaCOQNg zgTyYDhWo6gcqoCv7OlBV36uVVQ9Sc20tCCcOyUJxz0Qhj2JYHkGzqJmax8OQhuq nqLiBRG+FgEost5MeMBWxr4vqRxJ14ubKrgDtDXqJqMHxQ5mKgsApApDisjCj7VB zm5KgJk/eUwtVTmYuZDf/gJ5Byo6/A+nyYYU43A==; X-DKIM2-Info: draft=ietf-dkim-dkim2-spec-07; repo=github.com/dkim2wg/interop; date=2026-10-18; sw=lmtpprox; action=mi-m=1; hc=12; hn=cc,content-disposition,content-type,date,feedback-id,from, in-reply-to,message-id,mime-version,references,subject,to; Message-Instance: m=1; h=sha256:+r9T/KncapFsxWmDEmiZ/tDuFEdwHNavqW7I0Wt1hwU=:A1BrpImuUGD4k0iAb0OLrbd0v8/BTfk54ORNMFcQAGI=; X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: dmFkZTF63ov+h0NWgUoVn+Y8JeUnpYrateM1dWwrTqMD2nPb8I+4ZK3Ul/NvoAWryk/SIw F+97DqFkFsA9mt3NR5elFmSuXVffUEX9Bg10ACfE/RvNjrZTZcChQAnlaVTMtOQg5Cte0w BtD+c2QSsW+7KZyztGtxkv7Fs4rIRGnOGYo8McmR5CtjyYgpSnUY0v1v2z90E/PgcCKXiY 4cGqVpyf6Vz7MNsMZDU/VBdc8YDTeYQrsF4SB4wqRyfYwvcTGDGngHd41nfzAsY7lTw6Qh UpCHRvmeRzSbPhr0IKVGPcWcYz33PDz1xnYoMOP6kDMXoAEqpyMD61lwINoL3gLKIdIrkV cfWQOHsQ8p0hn1+oqGdvvKqFr2Exd/XQG+gMvbIE+S+BUfQIWRdXj8pltDsnMInraTN0TW TMwmzsXAn8c+E62dYSzip+oQHWVRiTQ1TOcIWpgXDwoyOj1QSwUlbckiEPAuW7hs1afkcm Grfu1pLOSzCVktojyGRAZGQoNxb4k3/oJ7WFRZPfUVOj58Drj2jrebeEf3srwuj+QsiJcv tJX3dKs/cuJrOjfccikKlJqY/MrDHrwFdLOi+BuIuPw4Drvc1DnT9I//yIH+7Op1jm7a6K M/zzS+1Cv2EQaAEWp/4PHiwGlP5veD+eb/ZTjxDOH+CDSFAMZfggrulF84XQ X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 26 Oct 2026 19:06:51 -0400 (EDT) Date: Tue, 27 Oct 2026 08:06:48 +0900 From: Michael Paquier To: Andres Freund Cc: Greg Burd , pgsql-hackers@postgresql.org, pgsql@j-davis.com, thomas.munro@gmail.com, exclusion@gmail.com, amit.kapila16@gmail.com, hlinnaka@iki.fi Subject: Re: WAL record CRC calculated incorrectly because of underlying buffer modification Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="AeGz+FrP7BBxtJR0" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --AeGz+FrP7BBxtJR0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Mon, Oct 26, 2026 at 09:46:18AM -0400, Andres Freund wrote: > I frankly think it's pretty much unacceptable for a niche index like hash to > violate the rules like that. If it were btree, it'd perhaps be worthwhile to > add generic infrastructure for this, but here it doesn't seem like the juice > is worth the squeeze. I'm definitely not convinced that hash is a sufficient argument for having more infrastructure. What this is telling us here is the contrary: we should have less infrastructure. So I'd love to be able to put REGBUF_NO_CHANGE in the garbage bin and have an assert in the replay code instead of silently ignoring a case. > I'm not really convinced by that argument. It's probably the best answer in > the back branches, but I think we shouldn't do this in master. I'm not sure that I can side with your argument here. Doing nothing on master means that we're still open to the CRC problem until we decide to fix hash, so it still looks like a problem that needs to be tackled in three steps: - Avoid the CRC problem down to v17, including HEAD. - Address hash to avoid the rule breakage. - Lift the check in replay for wal_consistency_checking (re-add the assert) and push REGBUF_NO_CHANGE into orbit. There is nothing more permanent than a temporary fix, as some say, but I'd like to trust in something happening for hash. I'm not planning to code that myself, though, but if somebody is willing to work that, be it with an LLM, I would read the code. That's just to say that I don't see a downside with including HEAD in step 1. -- Michael --AeGz+FrP7BBxtJR0 Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmrf3QgACgkQnvQgOdby QH0+iA//XhXM9dAGfNpeeNxU0B8Tqk9lUjgw8plGf+T2GZ2WetFr3MeIe3QdHe+h RH2wRAfkt1HsEiEbN3HWJuwtPvvY0Qtv74mLb/0FBN1hgsipd9/I+4T0zmT5bBLF AIiWYYEVDvtXJ7FMP6fD9cw8X1En3b1F2AXkrdJKDRD5Poe3kDd8qk5gjsSOiP3f 9YAxiOkyvwo1gcd8N9gwBXvWA8kt0pKaG5WHGW7oXtKycmPkN5WsC30eI7OT+TNe MZXjKn5FMe7fFwvbdoifI34sVAnPgjb0vux1NBod5/4HCetoivezDdKBQ2OtxEjc hOPNU1Pb3wW70+o0sjoXtlEH9mBrdulmyXMpT60tXNYsdSLUMaaByzqYB2y1eVeT nb7wywAh1axg4cQ5ns23FLkN2XVbgc/FX6hMpIdgl/Ff4XkFpmqx0mPTtJs6AnwQ /tdLr3BeCX/9px4gvF3oQ3lITq51rgI+OjGPD+IBPOu5gCvmZz7WoOQpdosUIr5c DSqxhhCLsl0hEOYr7mYp7hlM+m6pcBVBxF8TBVybPbNp++qty5PQFFJb5+HCcDDk KAeydrJuZKUeEIxoyl9Sqtk9vcRLwdSrezPjZ/W1B186SWF34ca8JMHGLbK6Dt5f Z5LJU5YJh2OSNK8itW2ADlxgjrAeC+M848jPKUVLzggpKYghvKU= =uOyE -----END PGP SIGNATURE----- --AeGz+FrP7BBxtJR0--