Re: On file locking
От | Tom Lane |
---|---|
Тема | Re: On file locking |
Дата | |
Msg-id | 8834.1044027292@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: On file locking (Antti Haapala <antti.haapala@iki.fi>) |
Ответы |
Re: On file locking
|
Список | pgsql-hackers |
Antti Haapala <antti.haapala@iki.fi> writes: > And from SunOS 5.8 flock > Locks are on files, not file descriptors. That is, file > descriptors duplicated through dup(2) or fork(2) do not > result in multiple instances of a lock, but rather multiple > references to a single lock. If a process holding a lock on > a file forks and the child explicitly unlocks the file, the > parent will lose its lock. Locks are not inherited by a > child process. That seems self-contradictory. If the fork results in multiple references to the open file, then I should think that if the parent dies but the child still holds the file open, then the lock still exists. Seems that some experimentation is called for ... regards, tom lane
В списке pgsql-hackers по дате отправления: