| From: | Bruce Momjian <bruce(at)momjian(dot)us> |
|---|---|
| To: | Thomas Munro <thomas(dot)munro(at)gmail(dot)com> |
| Cc: | walther(at)technowledgy(dot)de, Peter Eisentraut <peter(at)eisentraut(dot)org>, Christophe Pettus <xof(at)thebuild(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, PostgreSQL Bugs <pgsql-bugs(at)lists(dot)postgresql(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Subject: | Re: Regression tests fail with musl libc because libpq.so can't be loaded |
| Date: | 2024-03-22 00:07:14 |
| Message-ID: | ZfzLsiXbguTDatiZ@momjian.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-bugs pgsql-hackers |
On Fri, Mar 22, 2024 at 11:42:52AM +1300, Thomas Munro wrote:
> On Fri, Mar 22, 2024 at 9:30 AM <walther(at)technowledgy(dot)de> wrote:
> > > 4. The upstream (musl) suggestion of which I sent a PoC was to "exec
> > > yourself with a bigger argv".
> >
> > We could do this in HEAD now ...
>
> Just a thought: if we want to go this way, do we need a new exec call?
> We already control the initial exec in pg_ctl.c.
>
> > > Could we even use the exec-approach as the fallback in all other cases
> > > except BSDs and Windows and get rid of PS_USE_NONE?
> >
> > ... and then remove PS_USE_NONE at the beginning of the v18 cycle.
> >
> > This would give a bit more time for those "other systems", which were
> > previously falling back PS_USE_NONE and would then clobber argv, too.
>
> RIght. It's unspecified by POSIX whether ps shows changes to those
> strings (and there are systems that don't), but it can't hurt to do so
> anyway, and it'd be better than having a PS_USE_NONE code path that is
> untested. I dimly recall that it turned out that PS_USE_NONE was
> actually broken for a while without anyone noticing.
Actually, I was thinking the opposite. Since the musl libc is widely
used, it will be tested, and I don't want to disable process display
updates for such a common platform.
I suggest we use the #ifdef test to continue our existing behavior for
the libraries we know about, like glibc, and use the LD_* process title
truncation hack for libc's we don't recognize.
Attached is a prototype patch which implements this based on previous
patches.
--
Bruce Momjian <bruce(at)momjian(dot)us> https://momjian.us
EDB https://enterprisedb.com
Only you can decide what is important to you.
| Attachment | Content-Type | Size |
|---|---|---|
| proctitle.diff | text/x-diff | 1.2 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Bruce Momjian | 2024-03-22 00:08:49 | Re: Regression tests fail with musl libc because libpq.so can't be loaded |
| Previous Message | Tomas Vondra | 2024-03-21 23:58:09 | Re: Index plan returns different results to sequential scan |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Bruce Momjian | 2024-03-22 00:08:49 | Re: Regression tests fail with musl libc because libpq.so can't be loaded |
| Previous Message | Melih Mutlu | 2024-03-21 23:45:52 | Re: Flushing large data immediately in pqcomm |