pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Mischa Sandberg <mischa_sandberg@telus.net>
Cc: pgsql-hackers@postgresql.org
Subject: Re: postgresql in FreeBSD jails: proposal
Date: Wed, 16 Jan 2008 12:33:32 -0500
Message-ID: <25481.1200504812@sss.pgh.pa.us> (raw)
In-Reply-To: <1200503603.478e3b33346ca@webmail.telus.net>
References: <1200501702.478e33c61b74e@webmail.telus.net>
	<25135.1200503395@sss.pgh.pa.us>
	<1200503603.478e3b33346ca@webmail.telus.net>

Mischa Sandberg <mischa_sandberg@telus.net> writes:
> Quoting Tom Lane <tgl@sss.pgh.pa.us>:
>> Mischa Sandberg <mischa_sandberg@telus.net> writes:
>>> +               if (kill(1,0) && errno == ESRCH && PGSharedMemoryIsInUse(0,NextShmemSegID))
>>> +                       continue;
>> 
>> Isn't the last part of that test backward?  If it isn't, I don't
>> understand what it's for at all.

> Serious blush here. Yes.

Actually, after re-reading what PGSharedMemoryIsInUse does, I don't
think you want to use it: it goes to considerable lengths to avoid
returning a false positive, whereas in this context I believe we
*do* need to avoid segments that belong to other data directories.
So you probably need a separate chunk of code that only does the
nattch test.

			regards, tom lane



view thread (22+ messages)  latest in thread

Message-ID: <25481.1200504812@sss.pgh.pa.us>
Permalink:  ../25481.1200504812@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/25481.1200504812@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: tgl@sss.pgh.pa.us, mischa_sandberg@telus.net, pgsql-hackers@postgresql.org
  Subject: Re: postgresql in FreeBSD jails: proposal
  In-Reply-To: <25481.1200504812@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox