Re: Track IO times in pg_stat_io

From: Bertrand Drouvot <bertranddrouvot(dot)pg(at)gmail(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Melanie Plageman <melanieplageman(at)gmail(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>, Maciek Sakrejda <m(dot)sakrejda(at)gmail(dot)com>, Justin Pryzby <pryzby(at)telsasoft(dot)com>, smilingsamay(at)gmail(dot)com, Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, Lukas Fittl <lukas(at)fittl(dot)com>, Magnus Hagander <magnus(at)hagander(dot)net>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Subject: Re: Track IO times in pg_stat_io
Date: 2024-09-02 15:00:32
Message-ID: ZtXTEP9ZQkbgo8T5@ip-10-97-1-34.eu-west-3.compute.internal
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On Fri, Aug 23, 2024 at 07:32:16AM +0000, Bertrand Drouvot wrote:
> Hi,
>
> On Wed, Mar 08, 2023 at 04:34:38PM -0800, Andres Freund wrote:
> > On 2023-03-08 12:55:34 +0100, Drouvot, Bertrand wrote:
> > > - pg_stat_io is "global" across all sessions. So, even if one session is doing some "testing" and needs to turn track_io_timing on, then it
> > > is even not sure it's only reflecting its own testing (as other sessions may have turned it on too).
> >
> > I think for 17 we should provide access to per-existing-connection pg_stat_io
> > stats, and also provide a database aggregated version. Neither should be
> > particularly hard.
>
> FWIW, I think that would be great and plan to have a look at this (unless someone
> beats me to it).

FWIW, here is the patch proposal for per backend I/O statistics [1].

[1]: https://www.postgresql.org/message-id/ZtXR%2BCtkEVVE/LHF%40ip-10-97-1-34.eu-west-3.compute.internal

Regards,

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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Nazir Bilal Yavuz 2024-09-02 15:02:27 Re: PG_TEST_EXTRA and meson
Previous Message Bertrand Drouvot 2024-09-02 14:55:52 per backend I/O statistics