• Ghostcleanuptask thread wakes up every 10 seconds.
• Sweepdatabases one by one starting from master.
• Skip the database if it is not able to take ashared lock for database (LCK_M_S) or database is not in Open read/write state.
• Scans the PFS pages of the current database to get the pages which has ghost records.
1. PFS Page:A PFS page occurs once in 8088 pages. SSQL Server will attempt to place a PFS page on the first page of every PFS interval(8088Pages). The only time a PFS page is not the first page in its interval is in the first interval for a file.
2. In this case, the file header page is first, and the PFS page is second. (Page ID starts from 0 so the first PFS page is at Page ID 1)
• Remove the records which are marked as deleted (ghosted) physically
Submitted questions and answers are subject to review and editing, and may or may not be selected for posting, at the sole discretion of w3Sniff.
Get Started
Comments
Leave a Comment