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.94.2) (envelope-from ) id 1rPyXR-00Fa3U-1f for pgsql-hackers@arkaria.postgresql.org; Wed, 17 Jan 2024 05:32:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rPyXP-00Azlp-Sh for pgsql-hackers@arkaria.postgresql.org; Wed, 17 Jan 2024 05:32:31 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rPyXO-00AzlV-AN for pgsql-hackers@lists.postgresql.org; Wed, 17 Jan 2024 05:32:31 +0000 Received: from wout1-smtp.messagingengine.com ([64.147.123.24]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rPyXF-002Ey7-NU for pgsql-hackers@lists.postgresql.org; Wed, 17 Jan 2024 05:32:29 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id 91C563200AD7; Wed, 17 Jan 2024 00:32:15 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Wed, 17 Jan 2024 00:32:16 -0500 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=fm3; t=1705469535; x=1705555935; bh=50MF+bOZCl Yp14tkzbq3wrfLhl07F87nlqGJAe1XTvQ=; b=sUOZigQTQiisBzXwCRIALRwcEG hRr+PVVoa1Sm8PIIiYquE4WbnJaNoGoHmP6qMvHst6VoJPhYGCiKpxuhaoktYn5S ChIHktO0GOBA5Y1Ls64qvWbqUL7IkXFvmVL+EXEnCYGSZFV/itEWUrGCoohAAEhN OX8Yv906hl7URtsA4QWFjZczLKlWVoB4eOOUtHfJakPFExvY40Q3nDWc1ck8Y/Vf G+wgQlcS3eDnbJGTDkBPhss/okHgOMkduP3x5JNxeAG0hhTyHDdocuIq2P08pp94 LhKdWqWLVjQEHRiZpg3QWfbkxQmKhUnojnL3DAESTIzusAhWeVqOftwYTY4Q== 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-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; t=1705469535; x=1705555935; bh=50MF+bOZClYp14tkzbq3wrfLhl07 F87nlqGJAe1XTvQ=; b=j6322VmRZOrNpAMWNazg2gAhhkjnYReC2TqiED8X0+eH QFvm/TaXg0Lb2921y5Wz33u7oKNXePCepS3K9xtw+FjcgXAPM3HQW2nO7dsmmSeD HQ8gz9VgYwVlYHHidOKnERhJN0buTr/Pi+RgRikgCXS2LK6SFesvuWpSiFfvK5Zd p/7nqF3v2H87wj8CKLWqCoZB1xbuaJABAChYJrnC8myeDUUHVsU9EVyYOeokQZP0 vHtSRncsFXBH9ZFCUYAaql7LBKISfPGgDqf2MeevkFyFgT5EbXQ6LvZ0vLVK2x+k vIiCh3aFZSbzI1eCYwuUYdlhaqZAfHOLRHLtfh7SKA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvkedrvdejgedgkeegucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne gfrhhlucfvnfffucdljedtmdenucfjughrpeffhffvvefukfhfgggtuggjsehgtderredt tddvnecuhfhrohhmpefoihgthhgrvghlucfrrghquhhivghruceomhhitghhrggvlhesph grqhhuihgvrhdrgiihiieqnecuggftrfgrthhtvghrnhepteelieefudffhffhtdetleeg geegfffhkeeuveetiefgudduvedutefggeeivdejnecuvehluhhsthgvrhfuihiivgeptd enucfrrghrrghmpehmrghilhhfrhhomhepmhhitghhrggvlhesphgrqhhuihgvrhdrgiih ii X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 17 Jan 2024 00:32:10 -0500 (EST) Date: Wed, 17 Jan 2024 14:32:00 +0900 From: Michael Paquier To: Aleksander Alekseev Cc: pgsql-hackers@lists.postgresql.org, Kyotaro Horiguchi , vignesh21@gmail.com, stark.cfm@gmail.com, alvherre@alvh.no-ip.org, pryzby@telsasoft.com, andres@anarazel.de, ashu.coek88@gmail.com, pashkin.elfe@gmail.com, bossartn@amazon.com, david@pgmasters.net, peter.eisentraut@2ndquadrant.com, jtc331@gmail.com, robertmhaas@gmail.com Subject: Re: Make mesage at end-of-recovery less scary. Message-ID: References: <20240111.161816.1259268425616323411.horikyota.ntt@gmail.com> <20240116.115703.2298339297458587094.horikyota.ntt@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="6Wi7nEdfRKIQeQry" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --6Wi7nEdfRKIQeQry Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jan 16, 2024 at 02:46:02PM +0300, Aleksander Alekseev wrote: >> For now, let me explain the basis for this patch. The fundamental >> issue is that these warnings that always appear are, in practice, not >> a problem in almost all cases. Some of those who encounter them for >> the first time may feel uneasy and reach out with inquiries. On the >> other hand, those familiar with these warnings tend to ignore them and >> only pay attention to details when actual issues arise. Therefore, the >> intention of this patch is to label them as "no issue" unless a >> problem is blatantly evident, in order to prevent unnecessary concern. >=20 > I agree and don't mind affecting the error message per se. >=20 > However I see that the actual logic of how WAL is processed is being > changed. If we do this, at very least it requires thorough thinking. I > strongly suspect that the proposed code is wrong and/or not safe > and/or less safe than it is now for the reasons named above. FWIW, that pretty much sums up my feeling regarding this patch, because an error, basically any error, would hurt back very badly. Sure, the error messages we generate now when reaching the end of WAL can sound scary, and they are (I suspect that's not really the case for anybody who has history doing support with PostgreSQL because a bunch of these messages are old enough to vote, but I can understand that anybody would freak out the first time they see that). However, per the recent issues we've had in this area, like cd7f19da3468 but I'm more thinking about 6b18b3fe2c2f and bae868caf222, I am of the opinion that the header validation, the empty page case in XLogReaderValidatePageHeader() and the record read changes are risky enough that I am not convinced that the gains are worth the risks taken. The error stack in the WAL reader is complicated enough that making it more complicated as the patch proposes does not sound like not a good tradeoff to me to make the reports related to the end of WAL cleaner for the end-user. I agree that we should do something, but the patch does not seem like a good step towards this goal. Perhaps somebody would be more excited about this proposal than I am, of course. -- Michael --6Wi7nEdfRKIQeQry Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmWnZlAACgkQnvQgOdby QH2XXA//ZXJOLvsfWiCSkfF7jDCStdhq+OGV3byXxesPVgVx9nwdV9ukOQ2eFITw QIT0d8FibCmYX8uXq3K8/h5MgMYo8qVfGupFBhFLGbbY0Z1+ClTn2yogLgYmZiGi dRdEaC4V7MVceH2XyTuDeuMr+GHqF3IMd+jtjaAjwjYntR/nm6lSfaPxppu62fsZ tg2bTfHlCAjaTyur1r6BVcUtJpOJXTN8GR0x8ibN+MQBjKlsrthtGCT94INrghWw 6eZHxfzEuzFbR43XzJ84SZEupsiiihTyT8BQ/DZQ3vZD8KejUCAICC/WXW8ewt0K zoFVTv5HGFQnVbnu09A0d+7h6Ulp4acHvaQvOnYCWZOba4jMkZt+7Unfap6qUtt4 NsIrzCR9wiwaUsmyeB8FIl1vFRenj2aWRs3ug21g/UIyast9F9/w/QXL5w60GuYF 54sfp7qIJif52cKmuMxRvnfolAqobReN0xiAteiPO1xome1pPagMlhYkADjc1z1M JXOEVQfa+3A4yp9RlbPfouxsprsjAa3eisBWyAQc3XnRzOzF72w0yTnw0h3ZX675 qrvDYCGHmwewE1OzXeIZIACOzjE9HPtZeRT0NLn0E6PeTxi+nhlqUlLQFLuQA6Km QFIsHspLq5HuTbQrULpp9YTKZsnZxZp553LKD5oJxfqZ9OudiQA= =Sxhd -----END PGP SIGNATURE----- --6Wi7nEdfRKIQeQry--