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 1rXHpV-009mQV-0q for pgsql-bugs@arkaria.postgresql.org; Tue, 06 Feb 2024 09:33:25 +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 1rXHpU-002K8T-25 for pgsql-bugs@arkaria.postgresql.org; Tue, 06 Feb 2024 09:33:24 +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 1rXGUd-001lW1-4s for pgsql-bugs@lists.postgresql.org; Tue, 06 Feb 2024 08:07:47 +0000 Received: from mout.kundenserver.de ([212.227.126.134]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rXGUa-005j2t-E1 for pgsql-bugs@postgresql.org; Tue, 06 Feb 2024 08:07:46 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=oculeus.com; s=s1-ionos; t=1707206863; x=1707811663; i=baranowski@oculeus.com; bh=NeknQ/+KXLHzdxV2iuM98B/MMXIB+z0fNMrtVUzDYP0=; h=X-UI-Sender-Class:Subject:From:In-Reply-To:Date:Cc:References: To; b=lVg/iAYq7ZjCv2vimiFsDytTx4KdqF9Ahn7238q6qS9fI5wgXwjg/fkoLI8YPO8A cE1xq3EkM3eopD7KEo/57wSO88hlraaDE9T2G/T51aw6fiISiVXLUq2OMWoeQc+D9 0ju/3qMtIWwb9/8+Ozsl9Y6o6ZV4oYMW31Tc1Hl/dklTnhd17m4NsZgJpxl7rwae7 6IxAe0Z3fm2ajEPOPqW5BxZzA8u2JykPiilcE7zsdVhLY1QOXrtos5be0eMa1L4KJ WXgnR6Y5GbQpI+HE8x8I5pnA81g5rL4885OfVTPygR/udndJTEIHdbzFolWGDsjrC gYHG2KshS3Aw8AtUOg== X-UI-Sender-Class: 55c96926-9e95-11ee-ae09-1f7a4046a0f6 Received: from smtpclient.apple ([95.222.250.86]) by mrelayeu.kundenserver.de (mreue012 [212.227.15.167]) with ESMTPSA (Nemesis) id 1M28O9-1rZBMl3D7x-002aIi; Tue, 06 Feb 2024 09:07:42 +0100 Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.400.31\)) Subject: Re: PostgreSQL & latest Mac OS Sonoma, a possible bug / configuration issue From: Arnd Baranowski In-Reply-To: <319901.1707185894@sss.pgh.pa.us> Date: Tue, 6 Feb 2024 09:07:31 +0100 Cc: pgsql-bugs@postgresql.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <269596.1707165898@sss.pgh.pa.us> <319901.1707185894@sss.pgh.pa.us> To: Tom Lane X-Mailer: Apple Mail (2.3774.400.31) X-Provags-ID: V03:K1:w2/mk+KAvy2Bg+9HrNrVVMjqPIPL9NCCKSUyxHKC5OfrQGrsUxi Gy2gmMAqnqBhjrbxrsRjIXmPN7SM+L2zIgQAXnI9K5hxFRvHu4+bc4Hu+7tyrjsc+YTFux0 Q94qDzwVjYI2IPqLBbAZ3DlxOAjy7TJKwVBl5g8gUxWvget4teaIlrm0dO2ctk3jnUmTmtv 5SU5HoAksgSHh8n+l27/A== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:vM6M6eZi64g=;JF60r7rMlP31D6my5uC/D+W1Oga y4ynpYuPxDhjlhFEXFGjuUpN9vYn9uujLZuDyyQCzT6yi6ZK4h6YqRASn6P6yyo2ezwfcJlCR RnhGP63NTsJL8bzcjMLCm6iYsfDsMZkaWH89x1My5s3urm8BOUIV73dDRW+IUdi5JKsjlDwdb 7R7NofrgkycQfFqOUS0Soea1vCYQtqooe6dklgN2gIzc6PuleZjhlhW8LSZcD+tT7D6W2+20j 0nLT7VB/WsqFepcYYXHFWpMhr0Tapb19nx9hCWxlPgM1v93wdQXoi2A5R284wSfWTI8ytclr6 psG9SLzaklB/dxuZ9BWeN/5Kil8rh7WEMmcBw8madFSGWIAs6TgQi0X42ZtjoyeZOTcR9XEHQ ep+PHx7yqWqY1p4XKPRcTM2Li3CKl8E+ip3FfuBxxoe8nFq923+LuFidJYECVjonQmEIDS80w MO5Uvn+Ac4mp6rUJrNyysk8BcBXKOONLx/z+GyAMoRzJpeSkQE3QkhdTQtAcumvyNs3sq7X48 Lw+WJWkR0eU13CPJEhHFrS2zDlRU4jkXj8ijJliT43YqXiC18N6rUQL39H8wnQ/PcD7OV/Zqf Ylsy2SDZO6NelICsmgrgMhpfNqJNGPtSbd0K1kMBJP55lLAJ4pDdvNb4R6TxlG2pm2omXTTc/ QNHUCD6FAF252qjkmjq/JdDmACrCOh3+2daIUfhmbKv3EvZKEgpG07+dvCNYJdpAwV3QjZyqz 7pLBFp4cRRwNjZ3rHv7Xfwi6B1MJB3mAinBVtmL/KBZVf8qalaErqk= List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi Tom, Thanks for the feedback and insights. I will follow your advice, observe = and report if I find something which could explain this behavior Regard Arnd > Am 06.02.2024 um 03:18 schrieb Tom Lane : >=20 > Arnd Baranowski writes: >> Correction fsync is =E2=80=9EOn" and the wal_sync_method is set to = =E2=80=9Eopen_datasync=E2=80=9C >=20 > That's what they should be. >=20 > I tried to reproduce this by selecting "Restart..." immediately after > creating/populating a table on my own MacBook running Sonoma 14.3. > After the reboot, the table was there with the expected contents. > Now, this test doesn't actually prove a heck of a lot about PG's > crash recovery, because I see in the postmaster log >=20 > 2024-02-05 21:00:30.322 EST [1148] LOG: database system was shut down = at 2024-02-05 20:58:46 EST > 2024-02-05 21:00:30.327 EST [1144] LOG: database system is ready to = accept connections >=20 > which indicates that Postgres had time to perform a clean shutdown > before the system rebooted. (That is the expected scenario for an > OS reboot, assuming that the kernel delivers us SIGTERM as it's > required to do by POSIX and then gives us enough time to nail the > windows shut, which it's not required to do.) >=20 > The facts as you've presented them indicate that (1) checkpoints > weren't working, (2) we didn't get SIGTERM at system shutdown, *and* > (3) WAL wasn't written out to disk as it's supposed to be. It's > a bit hard to credit that so many things are broken and nobody has > noticed. I'm inclined to wonder if something is wrong with your > disk drive. >=20 > It would be interesting to know what appears in the first few lines > of your postmaster log after a data-losing restart. Also, try > running with log_checkpoints =3D on for awhile, and see if there are > log entries claiming successful checkpoint completion. >=20 > A different line of thought is that maybe the corruption is happening > because you have two postmasters started in the same data directory. > We have interlocks that are supposed to defend against that, but it'd > be a lot easier to credit that those aren't working than that all the > rest of this stuff broke. >=20 > regards, tom lane