← Back to Labs

Write-ahead log lifecycle

Run transactions, commit, checkpoint, crash, and recover. Watch the WAL make durability work.

MEMORY (volatile)log buffer (0)buffer pool0p00p10p20p30p40p5orange = dirty (LSN above disk)DISK (durable)WAL on disk (0) cp@0data files0p00p10p20p30p40p5
LSN 0idle

Start a transaction, update a page, commit. Watch records flow from the log buffer, to the disk log, and eventually to the data files after a checkpoint.

Shortcuts: B begin · 1-6 update · C commit · K checkpoint · Q crash · R recover · X reset
Tap buttons to run the lifecycle.
Read the full article →Take the quiz →