Re: [HACKERS] [sqlsmith] Crash reading pg_stat_activity - Mailing list pgsql-hackers

From Andreas Seltenreich
Subject Re: [HACKERS] [sqlsmith] Crash reading pg_stat_activity
Date
Msg-id 87inq5uf3q.fsf@ansel.ydns.eu
Whole thread Raw
In response to Re: [HACKERS] [sqlsmith] Crash reading pg_stat_activity  (Andreas Seltenreich <seltenreich@gmx.de>)
List pgsql-hackers
Andreas Seltenreich writes:

> Thomas Munro writes:
>
>> It is safe, as long as the segment remains mapped.  Each backend that
>> attaches calls LWLockRegisterTranche giving it the address of the name
>> in its virtual address space.
>
> Hmok, I was under the impression only backends participating in the IPC
> call the attach function, not necessarily the ones that could possible
> want to resolve the wait_event_info they found in the procArray via
> pgstat_get_wait_event().

Erm, ignore that question: They'll find a NULL in their
LWLockTrancheArray and run into the "extension" case you mentioned.

> But I really feel like I need to study the code a bit more before
> commenting further…

Following this advise now :-)

regards,
Andreas



pgsql-hackers by date:

Previous
From: Andreas Seltenreich
Date:
Subject: Re: [HACKERS] [sqlsmith] Crash reading pg_stat_activity
Next
From: Pavel Stehule
Date:
Subject: Re: [HACKERS] merging some features from plpgsql2 project