Re: Feature: POSIX Shared memory support

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Feature: POSIX Shared memory support
Дата
Msg-id 18001.1170787680@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Feature: POSIX Shared memory support  (Chris Marcellino <maps@levelview.com>)
Ответы Re: Feature: POSIX Shared memory support  ("Andrew Dunstan" <andrew@dunslane.net>)
Список pgsql-patches
Chris Marcellino <maps@levelview.com> writes:
> I was actually referring to the check that the current SysV code does
> on the pid that is stored in the shmem header. I presume that if the
> backend is dead, the kill(hdr->creatorPID, 0) returning zero would
> suffice for confirming the existence of the other backend process.

No, that's not relevant, because only the postmaster's PID will be there
--- that test is actually more or less redundant with the existing
postmaster.pid lockfile checks.  The thing that the SysV attachment
count is useful for is detecting whether there are orphaned backends
still alive in the database (and potentially changing it, hence the
danger).

We've speculated on occasion about using file locking in some form as a
substitute mechanism for detecting this, but that seems to just bring
its own set of not-too-portable assumptions.

            regards, tom lane

В списке pgsql-patches по дате отправления:

Предыдущее
От: Chris Marcellino
Дата:
Сообщение: Re: Feature: POSIX Shared memory support
Следующее
От: Gregory Stark
Дата:
Сообщение: WIP: Recursive Queries