Re: margay fails assertion in stats/dsa/dsm code

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Thomas Munro <thomas(dot)munro(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Marcel Hofstetter <hofstetter(at)jomasoft(dot)ch>
Subject: Re: margay fails assertion in stats/dsa/dsm code
Date: 2022-07-01 13:14:51
Message-ID: CA+TgmoaZDuUWK4MOb-8-hFFr+=oP9rqTE+bJOLynTxrXtTkQjA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Jun 30, 2022 at 10:34 PM Thomas Munro <thomas(dot)munro(at)gmail(dot)com> wrote:
> So... I think we should select a different default
> dynamic_shared_memory_type in initdb.c if defined(__sun__). Which is
> the least terrible? For sysv, it looks like all the relevant sysctls
> that used to be required to use sysv memory became obsolete/automatic
> in Sol 10 (note: Sol 9 is long EOL'd), so it should just work AFAICT,
> whereas for mmap mode your shared memory data is likely to cause file
> I/O because we put the temporary files in your data directory. I'm
> thinking perhaps we should default to dynamic_shared_memory_type=sysv
> for 15+. I don't really want to change it in the back branches, since
> nobody has actually complained about "posix" performance and it might
> upset someone if we change it for newly initdb'd DBs in a major
> release series. But I'm not an expert or even user of this OS, I'm
> just trying to fix the build farm; better ideas welcome.

Boy, relying on DSM for critical stuff sure is a lot of fun! This is
exactly why I hate adding new facilities that have to be implemented
in OS-dependent ways.

Changing the default on certain platforms to 'posix' or 'sysv'
according to what works best on that platform seems reasonable to me.
I agree that defaulting to 'mmap' doesn't seem like a lot of fun,
although I think it could be a reasonable choice on a platform where
everything else is broken. You could alternatively try to fix 'posix'
by adding some kind of code to work around that platform's
deficiencies. Insert handwaving here.

--
Robert Haas
EDB: http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2022-07-01 13:18:12 Re: pg_checkpointer is not a verb or verb phrase
Previous Message Robert Haas 2022-07-01 13:05:16 Re: replacing role-level NOINHERIT with a grant-level option