The ARIES Engine: How SQL Server Records Transaction History
SQL Server does not forget. Before modified data pages are written to disk, the engine records the history of what has changed. This is the foundation of ARIES (Algorithm for Recovery and Isolation Exploiting Semantics), a key part of reliable transaction processing.
“History is a system’s memory.” — SQLManiak
⚙️ Write-Ahead Logging (WAL)
Every modification in SQL Server is represented in the transaction log (.ldf):
- A log record describing the change is created, identified by an LSN (Log Sequence Number).
- The log record is flushed to durable storage.
- Only then may the modified data page be written to disk.
This is Write-Ahead Logging (WAL): log first, data page later. It allows SQL Server to recover after a failure.