question

narendba avatar image
narendba asked

Important sql server waits

I have seen scripts to find sql server waits like (CXPACKET, sos_schedular_yieald etc). Here I am looking for a script for identifying the waits and saving them into user defined table and depend upon the results, How we can able to finalize the resolution for solving the waits. I mean threshold for each and every wait and depend upon the stats will act accordingly that's my main goal. Do we have any benchmark script for troubleshoot the waits.
scriptsqlserver2012wait-typewaits
10 |1200 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
JohnM avatar image
JohnM answered
I'd start with Paul Randal's script here: http://www.sqlskills.com/blogs/paul/wait-statistics-or-please-tell-me-where-it-hurts/ Then modify it to start gathering wait stats on a time table (maybe once a day?) into a database/table of your choice. This would allow you to do some reporting on the waits. You can refer back to Paul's post to help point you in the right direction on resolving the wait. Hope that helps.
10 |1200 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.