Alvaro Herrera wrote:

> Oh, uh, the problem is that CreateSharedMemoryAndSemaphores wants to
> have access to the PGPROC already, but to obtain the PGPROC we need
> access to autovac shared memory (per AutoVacuumGetFreeProc).  So this
> wasn't too bright a choice :-(

It seems like I'll have to decouple autovacuum PGPROC's from
autovacuum's own shared memory.  The most sensible way to do this seems
to be to store them in ProcGlobal, along with the regular backend's
PGPROCs.  Is everyone OK with this plan?

Note that this will mean that those PGPROCs will be protected by the
same spinlock that protects the other PGPROCs.  I can't think of any
reason why this would be a problem, but if you think otherwise please
speak up.

Alvaro Herrera                      
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?


Reply via email to