Re: dynamic shared memory: wherein I am punished for good intentions

From: Claudio Freire <klaussfreire(at)gmail(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: dynamic shared memory: wherein I am punished for good intentions
Date: 2013-10-10 18:18:13
Message-ID: CAGTBQpaVRxB86=v4T0iVSuH303jzvH09uV-FRJMi2R3MCGr=Sw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Oct 10, 2013 at 1:13 PM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> (1) Define the issue as "not our problem". IOW, as of now, if you
> want to use PostgreSQL, you've got to either make POSIX shared memory
> work on your machine, or change the GUC that selects the type of
> dynamic shared memory used.
>
> (2) Default to using System V shared memory. If people want POSIX
> shared memory, let them change the default.
>
> (3) Add a new setting that auto-probes for a type of shared memory
> that works. Try POSIX first, then System V. Maybe even fall back to
> mmap'd files if neither of those works.
>
> (4) Remove the option to use POSIX shared memory. System V FTW!
>
> After some consideration, I think my vote is for option #2. Option #1
> seems too user-hostile, especially for a facility that has no in-core
> users yet, though I can imagine we might want to go that way
> eventually, especially if we at some point try to dump System V shared
> memory altogether, as has been proposed. Option #4 seems sad; we know
> that System V shared memory limits are a problem for plenty of people,
> so it'd be a shame not to have a way to use the POSIX facilities if
> they're available. Option #3 is fine as far as it goes, but it adds a
> significant amount of complexity I'd rather not deal with.
>
> Other votes? Other ideas?

I believe option 2 is not only good for now, but also a necessary
previous step in the way to option 3, which I believe should be the
goal.

So, ship a version with option 2, then implement 3, and make it the
default when enough people (using option 2) have successfully tested
pg's implementation of POSIX shared memory.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Josh Berkus 2013-10-10 18:18:28 Re: Auto-tuning work_mem and maintenance_work_mem
Previous Message Jeff Janes 2013-10-10 18:14:27 Re: Auto-tuning work_mem and maintenance_work_mem