Re: Add os_page_num to pg_buffercache

From: Bertrand Drouvot <bertranddrouvot(dot)pg(at)gmail(dot)com>
To: Tomas Vondra <tomas(at)vondra(dot)me>
Cc: Nathan Bossart <nathandbossart(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Add os_page_num to pg_buffercache
Date: 2025-07-02 06:39:25
Message-ID: aGTUHRgonWaYhyhL@ip-10-97-1-34.eu-west-3.compute.internal
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On Tue, Jul 01, 2025 at 07:46:30PM +0200, Tomas Vondra wrote:
> On 7/1/25 19:20, Bertrand Drouvot wrote:
> > Now it's just a matter of extracting the necessary pieces from pg_buffercache_numa_pages()
> > so that:
> >
> > * the new view could make use of it
> > * the maintenance burden should be low (thanks to code dedeuplication)
> > * people that don't have access to a platform that supports libnuma can have
> > access to this information
> >
>
> +1

PFA attached v3 adding a new view and function to pg_buffercache (both named
pg_buffercache_os_pages). I think the names are fine but not 100% convinced
though.

Regards,

--
Bertrand Drouvot
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com

Attachment Content-Type Size
v3-0001-Introduce-GET_MAX_BUFFER_ENTRIES-and-get_buffer_p.patch text/x-diff 3.6 KB
v3-0002-Add-pg_buffercache_os_pages-function-and-view.patch text/x-diff 18.5 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message vignesh C 2025-07-02 06:42:17 Invalid pointer access in logical decoding after error
Previous Message Shinya Kato 2025-07-02 06:37:49 Re: Add log_autovacuum_{vacuum|analyze}_min_duration