Re: Improve logging when using Huge Pages

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Cc: Justin Pryzby <pryzby(at)telsasoft(dot)com>, Nathan Bossart <nathandbossart(at)gmail(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, Michael Paquier <michael(at)paquier(dot)xyz>, Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, thomas(dot)munro(at)gmail(dot)com, tgl(at)sss(dot)pgh(dot)pa(dot)us, john(dot)naylor(at)enterprisedb(dot)com, noriyoshi(dot)shinoda(at)hpe(dot)com, jchampion(at)timescale(dot)com, sawada(dot)mshk(at)gmail(dot)com, masao(dot)fujii(at)oss(dot)nttdata(dot)com, pgsql-hackers(at)postgresql(dot)org, rjuju123(at)gmail(dot)com
Subject: Re: Improve logging when using Huge Pages
Date: 2023-03-09 20:15:29
Message-ID: ZAo+Yej4lz3b2bAH@tamriel.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Greetings,

* Alvaro Herrera (alvherre(at)alvh(dot)no-ip(dot)org) wrote:
> On 2023-Mar-09, Justin Pryzby wrote:
> > On Thu, Mar 09, 2023 at 09:34:10AM -0500, Stephen Frost wrote:
> > > > + Reports whether huge pages are in use by the current instance.
> > > > + See <xref linkend="guc-huge-pages"/> for more information.
> > > >
> > > > I still think we should say "server" in place of "current instance" here.
> > >
> > > We certainly use 'server' a lot more in config.sgml than we do
> > > 'instance'. "currently running server" might be closer to how we
> > > describe a running PG system in other parts (we talk about "currently
> > > running server processes", "while the server is running", "When running
> > > a standby server", "when the server is running"; "instance" is used much
> > > less and seems to more typically refer to 'state of files on disk' in my
> > > reading vs. 'actively running process' though there's some of each).
> >
> > I called it "instance" since the GUC has no meaning when it's not
> > running. I'm fine to rename it to "running server".
>
> I'd rather make all these other places use "instance" instead. We used
> to consider these terms interchangeable, but since we introduced the
> glossary to unify the terminology, they are no longer supposed to be.
> A server (== a machine) can contain many instances, and each individual
> instance in the server could be using huge pages or not.

Perhaps, but then the references to instance should probably also be
changed since there's certainly some that are referring to a set of data
files and not to backend processes, eg:

######
The <literal>shutdown</literal> setting is useful to have the instance
ready at the exact replay point desired. The instance will still be
able to replay more WAL records (and in fact will have to replay WAL
records since the last checkpoint next time it is started).
######

Not sure about just changing one thing at a time though or using the
'right' term when introducing things while having the 'wrong' term be
used next to it. Also not saying that this patch should be responsible
for fixing everything either. 'Server' in the glossary does explicitly
say it could be used when referring to an 'instance' too though, so
'running server' doesn't seem to be entirely wrong.

Thanks,

Stephen

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeff Davis 2023-03-09 20:17:53 Re: ICU locale validation / canonicalization
Previous Message Mark Dilger 2023-03-09 20:15:16 Re: BUG: Postgres 14 + vacuum_defer_cleanup_age + FOR UPDATE + UPDATE