• Right, now that I have time to write complex answers...

    Sachin Nandanwar (1/19/2011)


    If Lazywriter is supposed to "age out" dirty pages from data cache to the disk then what does checkpoint do ?

    Write all dirty pages down to reduce the time required for database recovery

    As per my understanding It is when the Lazywriter decides to flush the dirty pages to the disk that checkpoint occurs or are they two totally different processes?

    Two different processes. They both write dirty pages to disk, but that's where the similarity ends. They are run for different reasons with different aims. Checkpoint tries to write as many pages as fast as possible. Lazy writer tries to write as few as necessary.

    http://sqlinthewild.co.za/index.php/2009/06/26/the-lazy-writer-and-the-checkpoint/

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass