MSQL_XP wait stats measure the time a query waits while an extended stored procedure such as xp_cmdshell or xp_dirtree runs. On Night 20 at the Clipboard Diner, an outside caterer takes over one station behind a curtain. Then two queries show you which session is waiting and which procedure it called, and the fixes move that work outside SQL Server.
PREEMPTIVE Wait Stats: Calls Outside SQL Server
PREEMPTIVE wait stats record the time a task spends in code outside SQL Server, such as a call into Windows. On Night 19 at the Clipboard Diner, Kit picks up the wall phone to town hall and steps off the kitchen’s schedule. Then two queries find the preemptive waits that matter on your server.
LOGBUFFER Wait Stats: When the Log Buffer Fills
LOGBUFFER wait stats mean a task is waiting for free space in the log buffer before it can write a log record. On Night 18 at the Clipboard Diner, Pat’s notepad fills up faster than Pat can copy it into the order book. Then two queries show whether your log can keep up, and the fixes in order.
WRITELOG Wait Stats: Transaction Log Flush Waits
WRITELOG wait stats measure the time a commit waits for its log records to reach the disk. On Night 17 at the Clipboard Diner, Pat’s pen slows down and plates pile up at the pass. Then two queries show your log write latency, and a short script shows why many tiny commits hurt.
THREADPOOL Wait Stats: When Worker Threads Run Out
THREADPOOL wait stats mean a task is waiting for a worker thread because every worker is already busy. On Night 16 at the Clipboard Diner, every cook holds a ticket that can’t move, and nobody is free to take a new order. Then two queries show how close your server is to its worker limit, and how to get in when nobody else can.
LCK_M Wait Stats: Lock Waits and Blocking
LCK_M wait stats show how long queries wait for a lock that another session holds. On Night 15 at the Clipboard Diner, a party in booth 7 pays and then won’t leave, and three parties wait behind it. Then two queries find the blocking chain and its head blocker on your own server.
BACKUPIO Wait Stats: Why Backups Wait
BACKUPIO wait stats show a backup waiting on its own I/O, either reading the database or writing the backup file. On Night 14 at the Clipboard Diner, the night truck waits for empty crates and a slow gravel lot. You’ll see how BACKUPIO, BACKUPBUFFER and BACKUPTHREAD fit together, how to measure backup speed from msdb, and which fixes to try first, including ZSTD compression in SQL Server 2025.
