From: | "REIX, Tony" <tony(dot)reix(at)atos(dot)net> |
---|---|
To: | Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
Cc: | Andres Freund <andres(at)anarazel(dot)de>, Robert Haas <robertmhaas(at)gmail(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>, "EMPEREUR-MOT, SYLVIE" <sylvie(dot)empereur-mot(at)atos(dot)net> |
Subject: | RE: Shared Memory: How to use SYSV rather than MMAP ? |
Date: | 2019-10-03 13:22:54 |
Message-ID: | DB7PR02MB46631C413400C1A4F9848F41869C0@DB7PR02MB4663.eurprd02.prod.outlook.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi Thomas,
I've noticed that your patch adds:
+#if defined(SHM_LGPAGE)
+ /* AIX */
+ shmget_extra_flags = SHM_LGPAGE | SHM_PIN;
+#endif
However, my original patch contained:
| SHM_LGPAGE | SHM_PIN | S_IRUSR | S_IWUSR);
It looks like these 2 additional flags are specific to AIX and, as far as I remember, and based on the man of shmget() of AIX, there are required:
S_IRUSR
Permits the process that owns the data structure to read it.
S_IWUSR
Permits the process that owns the data structure to modify it.
So, I'm adding them to your patch.
I'm now trying to run the tests (some other weird issue during build before broke the whole process).
So, I think that I have to do this change in order to ask SystemV memory mapping on AIX:
--- ./src/bin/pg_upgrade/tmp_check/data/postgresql.conf.ORIGIN
+++ ./src/bin/pg_upgrade/tmp_check/data/postgresql.conf
-#shared_memory_type = mmap # the default is the first option
+shared_memory_type = sysv # the default is the first option
However, I do not master the details of which .conf file is used when testing.
Trying now to rebuild and hope tests will be launched this time.
Regards,
Tony
________________________________
De : Thomas Munro <thomas(dot)munro(at)gmail(dot)com>
Envoyé : mardi 10 septembre 2019 00:57
À : Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc : REIX, Tony <tony(dot)reix(at)atos(dot)net>; Andres Freund <andres(at)anarazel(dot)de>; Robert Haas <robertmhaas(at)gmail(dot)com>; Pg Hackers <pgsql-hackers(at)postgresql(dot)org>; EMPEREUR-MOT, SYLVIE <sylvie(dot)empereur-mot(at)atos(dot)net>
Objet : Re: Shared Memory: How to use SYSV rather than MMAP ?
On Wed, Sep 4, 2019 at 10:30 AM Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> wrote:
> On 2019-Feb-03, Thomas Munro wrote:
> > On Sat, Feb 2, 2019 at 12:49 AM Thomas Munro
> > <thomas(dot)munro(at)enterprisedb(dot)com> wrote:
> > > I am planning to commit the 0001 patch shortly, unless there are
> > > objections. I attach a new version, which improves the documentation
> > > a bit (cross-referencing the new GUC and the section on sysctl
> > > settings). That will give us shared_memory_type = sysv.
> >
> > Committed 0001.
>
> So can you please rebase what remains?
Here's a quick rebase. It needs testing, review and (probably)
adjustment from AIX users. I'm not going to be able to do anything
with it on my own due to lack of access, though I'm happy to help get
this committed eventually. If we don't get any traction in this CF,
I'll withdraw this submission for now. For consistency, I think we
should eventually also do the same thing for Linux when using sysv
(it's pretty similar, it just uses different flag names; it may also
be necessary to query the page size and round up the requested size,
on one or both of those OSes; I'm not sure).
ATOS WARNING !
This message contains attachments that could potentially harm your computer.
Please make sure you open ONLY attachments from senders you know, trust and is in an e-mail that you are expecting.
AVERTISSEMENT ATOS !
Ce message contient des pièces jointes qui peuvent potentiellement endommager votre ordinateur.
Merci de vous assurer que vous ouvrez uniquement les pièces jointes provenant d’emails que vous attendez et dont vous connaissez les expéditeurs et leur faites confiance.
AVISO DE ATOS !
Este mensaje contiene datos adjuntos que pudiera ser que dañaran su ordenador.
Asegúrese de abrir SOLO datos adjuntos enviados desde remitentes de confianza y que procedan de un correo esperado.
ATOS WARNUNG !
Diese E-Mail enthält Anlagen, welche möglicherweise ihren Computer beschädigen könnten.
Bitte beachten Sie, daß Sie NUR Anlagen öffnen, von einem Absender den Sie kennen, vertrauen und vom dem Sie vor allem auch E-Mails mit Anlagen erwarten.
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2019-10-03 13:39:56 | Re: WIP/PoC for parallel backup |
Previous Message | Святослав Ермилин | 2019-10-03 12:30:40 | Re: Close stdout and stderr in syslogger |