The document describes PostgreSQL's write-ahead logging (WAL) process. It shows how WAL records are written to the WAL buffer and flushed to WAL segments on disk. It also shows how the pd_lsn field in table pages is updated each time transactions are committed to reflect the last transaction that has been written to disk.