I understand sql server writes the updates to the data pages (making them dirty) in memory and writes the tlog onto the disk before sending the commit notification to the user.
This question is to ask in either of following scenarios:
- After flushing dirty pages from memory to disk
- Or after reboot post sql crash
How does the sql server know which dirty pages (data changes due to the recent set of tlogs) had been written to the disk or are yet to be written to disk?