Re: [HACKERS] flock patch breaks things here

From: The Hermit Hacker <scrappy(at)hub(dot)org>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Massimo Dal Zotto <dz(at)cs(dot)unitn(dot)it>, PostgreSQL Hackers <hackers(at)postgreSQL(dot)org>
Subject: Re: [HACKERS] flock patch breaks things here
Date: 1998-08-30 19:21:28
Message-ID: Pine.BSF.4.02.9808301618350.343-100000@thelab.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, 30 Aug 1998, Tom Lane wrote:

> Massimo Dal Zotto <dz(at)cs(dot)unitn(dot)it> writes:
> > In my opinion the socket and the pidfile should be created in a
> > directory owned by postgres, for example /tmp/.Pgsql-unix, like does X.
>
> The pidfile belongs at the top level of the database directory (eg,
> /usr/local/pgsql/data/postmaster.pid), because what it actually
> represents is that there is a postmaster running *for that database
> group*.

I have to agree with this one...but then it also negates the
argument about the flock() DoS...*grin*

BTW...I like the kill(pid,0) solution myself, primarily because it
is, i think, the most portable solution.

I would not consider a patch to remove the flock() solution and
replace it with the kill(pid,0) solution a new feature, just an
improvement of an existing one...either way, moving the pid file (or
socket, for that matter) from /tmp should be listed as a security related
requirement for v6.4 :)

Marc G. Fournier
Systems Administrator @ hub.org
primary: scrappy(at)hub(dot)org secondary: scrappy(at){freebsd|postgresql}.org

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message The Hermit Hacker 1998-08-30 19:22:11 Re: [HACKERS] pgindent for Monday
Previous Message The Hermit Hacker 1998-08-30 19:15:15 Re: [HACKERS] Release 6.4