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 1tb3Jp-007ZQ7-Ew for pgsql-hackers@arkaria.postgresql.org; Thu, 23 Jan 2025 19:56:49 +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 1tb3Jo-003hF7-Kn for pgsql-hackers@arkaria.postgresql.org; Thu, 23 Jan 2025 19:56:48 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tb3Jo-003hEz-1z for pgsql-hackers@lists.postgresql.org; Thu, 23 Jan 2025 19:56:48 +0000 Received: from mail-pj1-x102d.google.com ([2607:f8b0:4864:20::102d]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1tb3Jm-0019Dq-03 for pgsql-hackers@lists.postgresql.org; Thu, 23 Jan 2025 19:56:47 +0000 Received: by mail-pj1-x102d.google.com with SMTP id 98e67ed59e1d1-2ee397a82f6so2587216a91.2 for ; Thu, 23 Jan 2025 11:56:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=leadboat.com; s=google; t=1737662205; x=1738267005; darn=lists.postgresql.org; h=user-agent:in-reply-to:content-disposition:mime-version:references :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=yJItYkNuCv1nEyf5OvXuU790GZwz1hJKBWduiM05nUY=; b=FJIPC4S5XFDlp/EqUPeHlFPyXqkuvfoez/YqF9yQxdzP04eC1xn3BZw76rpf5ZDc/e 07RSPeA4q8ocSAfGEgcQbEC5d+GEXqOfEm4Q9uFuKRT3zJaVdkPN3lnRdmFK1fJ5P/bt jWI4Xf4gg6lqLV358gaQ4I3lPY1NMbx9KMPcE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1737662205; x=1738267005; h=user-agent:in-reply-to:content-disposition:mime-version:references :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yJItYkNuCv1nEyf5OvXuU790GZwz1hJKBWduiM05nUY=; b=drCVZ74emKIwPI0Z2vwLrgmbSFvavnCn6LJt1JpVaihSgcncFV7VgWvRrY6rzbWd7l Plor7lM/qOJkqP/GxgSkCn4EJMUqqldszTwjYpxVo8qN3CoqIlbkQ9WfVXl+sNyJpw0A hkBjA/nALXSt7nmNVd3JWwvT+wNEt1FAWFudtnJjJ7qV3fsrPP+lRoFaxLNLlRsP3KnX kxjNscfji/JXfBa9U7Y2kjmhhoALCFI61oBQrJopubn5gHjzStl/0V1LVclgqTg8Bpp/ /yCUcN9Udvwtoe+XdgIU2o4lr3GEcEHnCOZ32LtG2VtRq72XfhlS54PaYfZeuJ7fr9x0 vqig== X-Gm-Message-State: AOJu0YysQ8IKi//lnH1QS0/fLWzHqPnY6jO/C+kVf4P7fj5c10bLVK+E ISuPo6M8YUxtt7F2aqyONvb4idUYkcYQhhrPaYHBSN2FblWvLZ3xb1/YcVtXDQ== X-Gm-Gg: ASbGnctPdhhefRLFFQ9ooSm2tU186GLOKcZxA2y51iStoQjjns8Rd9P6CsZvlp3WC4l qjFHdfjXOh1fZ8UTXWAkNGBoh2ithcLQBfID64lCbMxOpGIIleAdW1LB7jKT0UxWV4FxGvqOccC Oo9XFvgsZRqQy7bLgRS6SjRJlgdiZTXNYe3xZqm/Y8BUjZW3XPpJ2C3B4PixHdcIOa24OcrF8sW ojEfOkhaxtXKOQztXAD/5VxZG3nuuwyl2Wkya4J4Q88icwqlNE4kZJ65pjF5iiJha77OES6NIM= X-Google-Smtp-Source: AGHT+IFHYgDuKfsGIiaq0HZr5BR18oXAYsjxNhNpUk22nzwMxTThnPv7iZ8DYGpnIMJyGoLkER8eWA== X-Received: by 2002:a17:90b:5206:b0:2f5:63a:44f9 with SMTP id 98e67ed59e1d1-2f782d4f189mr34567065a91.23.1737662205533; Thu, 23 Jan 2025 11:56:45 -0800 (PST) Received: from google.com ([2600:1702:a20:5750::46]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2f7ffa56661sm105262a91.12.2025.01.23.11.56.44 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 23 Jan 2025 11:56:45 -0800 (PST) Date: Thu, 23 Jan 2025 11:56:43 -0800 From: Noah Misch To: Tom Lane Cc: pgsql-hackers@lists.postgresql.org Subject: Re: "postmaster became multithreaded" is reachable Message-ID: <20250123195643.88.nmisch@google.com> References: <206317.1737656533@sss.pgh.pa.us> <20250123183837.79.nmisch@google.com> <209558.1737658292@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <209558.1737658292@sss.pgh.pa.us> User-Agent: Mutt/2.2.12 (2023-09-09) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, Jan 23, 2025 at 01:51:32PM -0500, Tom Lane wrote: > Noah Misch writes: > > On Thu, Jan 23, 2025 at 01:22:13PM -0500, Tom Lane wrote: > >> An alternative idea (that maybe should also be done in PostmasterMain) > >> is to report the HINT only #ifdef __darwin__ and on other platforms > >> use the "Please report a bug" text. > > > I gather pthread_is_threaded_np() is still macOS-only, in which case the > > !darwin branch would be future-proofing only. > > Ah, I had not realized that. Perhaps the comments about this code > should mention that? Sure, your committed comment works for me. > > Another alternative would be to track whether we reached the startup-time > > check, emitting a message at exit only if we did reach the startup-time check. > > If a postmaster passes the startup-time check and fails the exit-time check, > > changing the environment won't help. Even so, I'm content with your first > > proposal. > > Yeah, seems like overcomplication. Let's go with the simple way. postgr.es/c/4f15759bdcddd23e874526a6b2c0ff86e0beb042 looks fine. Thanks.