跳转到主要内容
← 目录图谱 / pg_stat_checkpointer

STATISTICS VIEW · 统计视图

pg_stat_checkpointer

The pg_stat_checkpointer view will always have a single row, containing data about the checkpointer process of the cluster. Checkpoints may be skipped if the server has been idle since the last one. num_timed and num_requested count both completed and skipped checkpoints, while num_done tracks only the completed ones. Similarly, restartpoints may be skipped if the last replayed checkpoint record is already the last restartpoint. restartpoints_timed and restartpoints_req count both completed and skipped restartpoints, while restartpoints_done tracks only the completed ones.

首次收录 PG 17最近收录 PG 19当前字段 11

已与 PostgreSQL 18.6 实例逐字段核对 · 原始实测记录 ↗

字段结构 PostgreSQL 18

pg_stat_checkpointer
字段 / COLUMN类型 / TYPE说明 / DESCRIPTION
num_timed bigint Number of scheduled checkpoints due to timeout
num_requested bigint Number of requested checkpoints
num_done bigint Number of checkpoints that have been performed
restartpoints_timed bigint Number of scheduled restartpoints due to timeout or after a failed attempt to perform it
restartpoints_req bigint Number of requested restartpoints
restartpoints_done bigint Number of restartpoints that have been performed
write_time double precision Total amount of time that has been spent in the portion of processing checkpoints and restartpoints where files are written to disk, in milliseconds
sync_time double precision Total amount of time that has been spent in the portion of processing checkpoints and restartpoints where files are synchronized to disk, in milliseconds
buffers_written bigint Number of shared buffers written during checkpoints and restartpoints
slru_written bigint Number of SLRU buffers written during checkpoints and restartpoints
stats_reset timestamp with time zone Time at which these statistics were last reset

标记“隐式列”的字段不包含在 SELECT * 中;部分早期统计视图由同版本源码补全,额外来源会显示在字段说明中。

字段演化矩阵

悬停查看字段类型
存在新增 / 类型或属性变化移除
字段 / COLUMN9.09.19.29.39.49.59.610111213141516171819
num_timed
num_requested
restartpoints_timed
restartpoints_req
restartpoints_done
write_time
sync_time
buffers_written
stats_reset
num_done
slru_written

9.0 是收录基线;基线中已存在的字段不标记为新增。矩阵按字段名称对齐,重命名显示为旧字段移除与新字段新增。

演化时间线

相邻大版本的变化

PostgreSQL 18 ← 17

+ num_done+ slru_written3 处字段说明更新目录说明更新

PostgreSQL 17 ← 16新增目录

+ num_timed+ num_requested+ restartpoints_timed+ restartpoints_req+ restartpoints_done+ write_time+ sync_time+ buffers_written+ stats_reset

比较任意两个版本

选择两个版本,查看字段的新增、移除与类型变化。交互比较需要 JavaScript;演化时间线可直接阅读。