Re: file-locking and postmaster.pid - Mailing list pgsql-hackers

From Tom Lane
Subject Re: file-locking and postmaster.pid
Date
Msg-id 2905.1148511214@sss.pgh.pa.us
Whole thread Raw
In response to Re: file-locking and postmaster.pid  (Alvaro Herrera <alvherre@commandprompt.com>)
List pgsql-hackers
Alvaro Herrera <alvherre@commandprompt.com> writes:
> Well, you are wrong here.  We _want_ every backend to hold a shared
> lock.  We need to stop a postmaster from starting if there is a backend
> running that was started by a no-longer-running postmaster.

Note that we currently rely on checking for SysV shared memory attach
counts to protect against this case; the postmaster PID doesn't enter
into it.  We don't have to insist on the postmaster interlock handling
this too.  (Although surely it'd be nice to not depend on SysV attach
counts for this, because that's a portability issue in itself.)
        regards, tom lane


pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: file-locking and postmaster.pid
Next
From: korry
Date:
Subject: Re: file-locking and postmaster.pid