Checkpoints and the Active Portion of the Log
Checkpoints flush dirty data pages from the buffer cache of the current database to disk. This minimizes the active portion of the log that must be processed during a full recovery of a database. During a full recovery, the following types of actions are
The log records of modifications not flushed to disk before the system stopped are rolled forward.
All modifications associated with incomplete transactions, such as transactions for which there is no COMMIT or ROLLBACK log record, are rolled back.
I don't understand this BOL page... From what I read in the first sentence above, the following must be true:
I understand that SQL Server apparently doesn't save updated data directly to disk but stores it in RAM (the so-called Buffer Cache) until either this RAM buffer is full or until a checkpoint operation is executed.
If this is tue,
Isn't this quite dangerous? What happens if the server is powered off? Are all updates that had been stored in the Buffer Cache / Log Cache lost?
After a server restart, how can "The log records of modifications not flushed to disk before the system stopped"
possibly be "rolled forward" if they had been stored in the Buffer Cache? After a server restart the Buffer Cache and the Log Cache must be empty! So there are no
View Complete Post