On Wed, Feb 1, 2023 at 3:02 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
> > 2023-01-24 02:35:45.833 PST [3424807] LOG: PID 0 in cancel request did not
> > match any process
> > *Error locking mutex 22*
>
> The first of those lines comes from this bit in postmaster.c:
>
> /* No matching backend */
> ereport(LOG,
> (errmsg("PID %d in cancel request did not match any process",
> backendPID)));
>
> As you can see, that would not have generated anything about a mutex.
> The string "locking mutex" appears nowhere in the Postgres sources;
> in fact, so far as I can find we don't use the word "mutex" in any
> message whatever.
I wonder if 22 might be EINVAL, which is one possible error code used
by pthread_mutex_lock().
--
Peter Geoghegan