postgresql-timeline · shipping · also WAL timeline

PostgreSQL timeline

A PostgreSQL timeline identifies a branch of a database cluster's write-ahead-log history.

Related Observatory article: PostgreSQL timeline on hesela.com

Completing archive recovery creates a new branch for subsequent WAL, preserving the earlier history. Timeline IDs distinguish WAL filenames. [1]

Selection: recovery_target_timeline accepts an ID, current for the base backup's timeline, or latest, the default. This selects history, not the replay stopping point. [2]

Interpretation: a larger timeline ID alone does not establish ancestry or possession of another branch's commits. Compare cluster identity, timeline history and the named LSN progress stage together. IDENTIFY_SYSTEM reports systemid, timeline and the current WAL flush position separately. [3] [4]

Backup scope: a standby following an upstream promotion during a base backup can require WAL ranges on several timelines. The manifest retains the timeline for each range rather than one unqualified byte interval. [6]

Relations

related
Timeline history file (PostgreSQL), Log sequence number, Replication lag, Point-in-time recovery, Recovery target, Backup manifest

Citations

  1. PostgreSQL 18: Timelines (accessed 2026-10-20)
  2. PostgreSQL 18: recovery_target_timeline (accessed 2026-10-20)
  3. PostgreSQL 18: IDENTIFY_SYSTEM and TIMELINE_HISTORY (accessed 2026-10-20)
  4. PostgreSQL 18.0: timeline history reader and writer (accessed 2026-10-20)
  5. PostgreSQL 18: Backup Manifest WAL Range Object (accessed 2026-10-21)

Further reading

  1. Hesela: Replication acknowledgements: received, durable, applied (accessed 2026-10-20)

JSON: /data/terms/postgresql-timeline.json

Published by Hesela team · Updated

Report a correction · Editorial standards · Reuse guidance

Cite this page
Hesela team. PostgreSQL timeline. Hesela. 2026-10-21. https://hesela.dev/terms/postgresql-timeline/