pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Fix temporary relation I/O statistics in single-user mode 5+ messages / 1 participants [nested] [flat]
* pgsql: Fix temporary relation I/O statistics in single-user mode @ 2026-11-18 07:10 Fujii Masao <fujii@postgresql.org> 0 siblings, 0 replies; 5+ messages in thread From: Fujii Masao @ 2026-11-18 07:10 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix temporary relation I/O statistics in single-user mode Accessing temporary relations in single-user mode could trigger an assertion failure in assertion-enabled builds. For example, CREATE TEMP TABLE AS and CREATE TEMP SEQUENCE failed when recording relation extension statistics. Without assertions, the statistics were still collected internally but were not exposed in pg_stat_io. The problem was that pgstat_tracks_io_object() incorrectly excluded standalone backends from I/O tracking for temporary relations, even though they use local buffers just like regular client backends. Remove this exclusion to prevent the assertion failures and make the statistics visible in pg_stat_io. Backpatch to v16, where the incorrect exclusion was introduced in commit 28e626bde00. Author: Manuel Reyes Bravo <manuelreyesbravo@gmail.com> Reviewed-by: Fujii Masao <masao.fujii@gmail.com> Discussion: https://postgr.es/m/179487554022.104798.7544124224648387746@gmail.com Backpatch-through: 16 Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/45047c51aab3b02035217088ef35220b2be905d7 Modified Files -------------- src/backend/utils/activity/pgstat_io.c | 14 +++++++------- src/test/regress/expected/stats.out | 3 ++- 2 files changed, 9 insertions(+), 8 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
* pgsql: Fix temporary relation I/O statistics in single-user mode @ 2026-11-18 07:10 Fujii Masao <fujii@postgresql.org> 0 siblings, 0 replies; 5+ messages in thread From: Fujii Masao @ 2026-11-18 07:10 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix temporary relation I/O statistics in single-user mode Accessing temporary relations in single-user mode could trigger an assertion failure in assertion-enabled builds. For example, CREATE TEMP TABLE AS and CREATE TEMP SEQUENCE failed when recording relation extension statistics. Without assertions, the statistics were still collected internally but were not exposed in pg_stat_io. The problem was that pgstat_tracks_io_object() incorrectly excluded standalone backends from I/O tracking for temporary relations, even though they use local buffers just like regular client backends. Remove this exclusion to prevent the assertion failures and make the statistics visible in pg_stat_io. Backpatch to v16, where the incorrect exclusion was introduced in commit 28e626bde00. Author: Manuel Reyes Bravo <manuelreyesbravo@gmail.com> Reviewed-by: Fujii Masao <masao.fujii@gmail.com> Discussion: https://postgr.es/m/179487554022.104798.7544124224648387746@gmail.com Backpatch-through: 16 Branch ------ REL_19_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/079619ae93398e0ac1c7a24897694b0fb74840df Modified Files -------------- src/backend/utils/activity/pgstat_io.c | 14 +++++++------- src/test/regress/expected/stats.out | 3 ++- 2 files changed, 9 insertions(+), 8 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
* pgsql: Fix temporary relation I/O statistics in single-user mode @ 2026-11-18 07:10 Fujii Masao <fujii@postgresql.org> 0 siblings, 0 replies; 5+ messages in thread From: Fujii Masao @ 2026-11-18 07:10 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix temporary relation I/O statistics in single-user mode Accessing temporary relations in single-user mode could trigger an assertion failure in assertion-enabled builds. For example, CREATE TEMP TABLE AS and CREATE TEMP SEQUENCE failed when recording relation extension statistics. Without assertions, the statistics were still collected internally but were not exposed in pg_stat_io. The problem was that pgstat_tracks_io_object() incorrectly excluded standalone backends from I/O tracking for temporary relations, even though they use local buffers just like regular client backends. Remove this exclusion to prevent the assertion failures and make the statistics visible in pg_stat_io. Backpatch to v16, where the incorrect exclusion was introduced in commit 28e626bde00. Author: Manuel Reyes Bravo <manuelreyesbravo@gmail.com> Reviewed-by: Fujii Masao <masao.fujii@gmail.com> Discussion: https://postgr.es/m/179487554022.104798.7544124224648387746@gmail.com Backpatch-through: 16 Branch ------ REL_18_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/4d6ff8a051a13b7c86255ff5d83ff2aa0dce302a Modified Files -------------- src/backend/utils/activity/pgstat_io.c | 14 +++++++------- src/test/regress/expected/stats.out | 3 ++- 2 files changed, 9 insertions(+), 8 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
* pgsql: Fix temporary relation I/O statistics in single-user mode @ 2026-11-18 07:10 Fujii Masao <fujii@postgresql.org> 0 siblings, 0 replies; 5+ messages in thread From: Fujii Masao @ 2026-11-18 07:10 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix temporary relation I/O statistics in single-user mode Accessing temporary relations in single-user mode could trigger an assertion failure in assertion-enabled builds. For example, CREATE TEMP TABLE AS and CREATE TEMP SEQUENCE failed when recording relation extension statistics. Without assertions, the statistics were still collected internally but were not exposed in pg_stat_io. The problem was that pgstat_tracks_io_object() incorrectly excluded standalone backends from I/O tracking for temporary relations, even though they use local buffers just like regular client backends. Remove this exclusion to prevent the assertion failures and make the statistics visible in pg_stat_io. Backpatch to v16, where the incorrect exclusion was introduced in commit 28e626bde00. Author: Manuel Reyes Bravo <manuelreyesbravo@gmail.com> Reviewed-by: Fujii Masao <masao.fujii@gmail.com> Discussion: https://postgr.es/m/179487554022.104798.7544124224648387746@gmail.com Backpatch-through: 16 Branch ------ REL_17_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/e9b2d85c145d0f9132b7c9eebc2bde0b343ab87b Modified Files -------------- src/backend/utils/activity/pgstat_io.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
* pgsql: Fix temporary relation I/O statistics in single-user mode @ 2026-11-18 07:10 Fujii Masao <fujii@postgresql.org> 0 siblings, 0 replies; 5+ messages in thread From: Fujii Masao @ 2026-11-18 07:10 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix temporary relation I/O statistics in single-user mode Accessing temporary relations in single-user mode could trigger an assertion failure in assertion-enabled builds. For example, CREATE TEMP TABLE AS and CREATE TEMP SEQUENCE failed when recording relation extension statistics. Without assertions, the statistics were still collected internally but were not exposed in pg_stat_io. The problem was that pgstat_tracks_io_object() incorrectly excluded standalone backends from I/O tracking for temporary relations, even though they use local buffers just like regular client backends. Remove this exclusion to prevent the assertion failures and make the statistics visible in pg_stat_io. Backpatch to v16, where the incorrect exclusion was introduced in commit 28e626bde00. Author: Manuel Reyes Bravo <manuelreyesbravo@gmail.com> Reviewed-by: Fujii Masao <masao.fujii@gmail.com> Discussion: https://postgr.es/m/179487554022.104798.7544124224648387746@gmail.com Backpatch-through: 16 Branch ------ REL_16_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/c475754aa1829ec3e706881188550b6667044d28 Modified Files -------------- src/backend/utils/activity/pgstat_io.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
end of thread, other threads:[~2026-11-18 07:10 UTC | newest] Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2026-11-18 07:10 pgsql: Fix temporary relation I/O statistics in single-user mode Fujii Masao <fujii@postgresql.org> 2026-11-18 07:10 pgsql: Fix temporary relation I/O statistics in single-user mode Fujii Masao <fujii@postgresql.org> 2026-11-18 07:10 pgsql: Fix temporary relation I/O statistics in single-user mode Fujii Masao <fujii@postgresql.org> 2026-11-18 07:10 pgsql: Fix temporary relation I/O statistics in single-user mode Fujii Masao <fujii@postgresql.org> 2026-11-18 07:10 pgsql: Fix temporary relation I/O statistics in single-user mode Fujii Masao <fujii@postgresql.org>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox