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 1rmkjs-009eGK-Vd for pgsql-bugs@arkaria.postgresql.org; Wed, 20 Mar 2024 01:27:33 +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 1rmkjr-001SGs-8a for pgsql-bugs@arkaria.postgresql.org; Wed, 20 Mar 2024 01:27: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 1rmkjr-001SGk-0E for pgsql-bugs@lists.postgresql.org; Wed, 20 Mar 2024 01:27:31 +0000 Received: from momjian.us ([72.94.173.45]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rmkjn-005Sjp-6s for pgsql-bugs@lists.postgresql.org; Wed, 20 Mar 2024 01:27:30 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=momjian.us; s=2024011501; h=In-Reply-To:Content-Transfer-Encoding:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-ID:Content-Description; bh=lyDLJPBOZHu7uO7N2IBSyOppnveSXEQes7Nzm4n+fpM=; b=Zv2InRnjqTU3kliT+LbHBUsP9p kLgymB+z38Q05PW+0S5R+Jnkd1f4jcc4kKW3QiG/cdrIoe57LGLyhLACNhDAo4NfHBhu00KwBW2Zp I8UI1NaF4V5uHuZc8kYKCvD6OHk/MD2EcC64aPXqm0OklpIMvzrL84eKBosC5ne1u2/2pXVNguqYN B19zICa4P/31WFe6wzxtpEq87tzwubqA3nBut6PPy+cbAEl/8Fn+YMagm4ogDFfqYWCVtdejX8ze0 V+zgDh46iedZzseRSD13aZcX9skuBTuU1DaMFmgQlz+dQVSNmYoIyPk9vlV80AKqiGKrcqwZeXAGb /UPi1zGw==; Received: from bruce by momjian.us with local (Exim 4.96) (envelope-from ) id 1rmkjj-00CbMR-21; Tue, 19 Mar 2024 21:27:23 -0400 Date: Tue, 19 Mar 2024 21:27:23 -0400 From: Bruce Momjian To: Thomas Munro Cc: Tom Lane , Christophe Pettus , Andrew Dunstan , Wolfgang Walther , PostgreSQL Bugs Subject: Re: Regression tests fail with musl libc because libpq.so can't be loaded Message-ID: References: <3561573.1710771812@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, Mar 20, 2024 at 02:12:54PM +1300, Thomas Munro wrote: > On Wed, Mar 20, 2024 at 12:54 PM Bruce Momjian wrote: > > So this would truncate the process title on all Linux that have an LD_ > > environment entry, even those without musl? > > Yep. How long is /proc/XXX/cmdline (check with wc -c /proc/...) in a > postmaster near you? You'd always get that much, plus as much of $ cat /proc/2000/cmdline |wc -c 30 > /proc/XXX/environ as we can find before you reach LD_XXX=, which on a > typical system would, I guess, usually be never. If it's a problem > you could try to arrange for LD_ XXX to come later in environ[]. What > I observe is that they seem to get copied in backwards, wrt the > environment exported by the parent, so if you set DUMMY=XXXXXXXX just > before starting the process it'll make sacrificial space in the right > place (but I'm not sure where that effect is coming from so don't > quote me). I am just cautious about changing behavior on our most common platform for a libc library I have never heard of. -- Bruce Momjian https://momjian.us EDB https://enterprisedb.com Only you can decide what is important to you.