Re: per backend I/O statistics
Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
From: Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
To: Michael Paquier <michael@paquier.xyz>
Cc: Nazir Bilal Yavuz <byavuz81@gmail.com>, Alvaro Herrera <alvherre@alvh.no-ip.org>, Kyotaro Horiguchi <horikyota.ntt@gmail.com>, pgsql-hackers@lists.postgresql.org
Date: 2024-12-19T06:12:04Z
Lists: pgsql-hackers
Hi, On Thu, Dec 19, 2024 at 01:21:54PM +0900, Michael Paquier wrote: > > While doing more tests with backends exiting concurrently with their > stats scanned, I have detected one path in pg_stat_get_backend_io() > after calling pgstat_get_beentry_by_proc_number() where we should also > check that it does not return NULL, or we would crash on a pointer > dereference when reading the backend type. > > Fixed that, Oh right, indeed all the others pgstat_get_beentry_by_proc_number() callers are checking for a NULL returned value. > bumped the two version counters, and done. Thanks! I think I'll start a dedicated thread to discuss the stats_fetch_consistency/'snapshot' point (will be easier to follow than resuming the discussion in this thread). Regards, -- Bertrand Drouvot PostgreSQL Contributors Team RDS Open Source Databases Amazon Web Services: https://aws.amazon.com
Commits
-
Rework handling of pending data for backend statistics
- 4feba03d8b92 18.0 landed
-
Rename some pgstats callbacks related to flush of entries
- 28de66cee5f4 18.0 landed
-
Relax regression test for fsync check of backend-level stats
- 546371599e76 18.0 landed
-
Add backend-level statistics to pgstats
- 9aea73fc61d4 18.0 landed
-
Extract logic filling pg_stat_get_io()'s tuplestore into its own routine
- ff7c40d7fd6a 18.0 landed
-
Tweak some comments related to variable-numbered stats in pgstat.c
- fee2b3ea2ecd 18.0 landed