A parameter determining whether to track timing of WAL I/O
This entry relates to a PostgreSQL feature which is part of PostgreSQL 14, due to be released in late 2021.

track_wal_io_timing is a configuration parameter timing of WAL I/O calls.

track_wal_io_timing was added in PostgreSQL 14.

Default value

The default value for track_wal_io_timing is: off.


If set to on, track_wal_io_timing will track statistics for WAL input/output operations. The accumulated statistics can be retrieved via the following columns of pg_stat_wal:

  • wal_write_time
  • wal_sync_time

Note that if enabled, track_wal_io_timing will cause PostgreSQL to query the operating system for the current time whenever WAL is written or synced, which may cause significant overhead on some platforms.

Change history


Sample contents of pg_stat_wal with track_wal_io_timing set to on:

postgres=# SELECT * FROM pg_stat_wal\gx
-[ RECORD 1 ]----+------------------------------
wal_records      | 301882
wal_fpi          | 135
wal_bytes        | 18544842
wal_buffers_full | 603
wal_write        | 633
wal_sync         | 5
wal_write_time   | 4.13
wal_sync_time    | 219.9
stats_reset      | 2021-03-09 11:06:01.842869+01


GUC configuration item, Monitoring, WAL

See also

pg_stat_wal, track_io_timing