sys.dm_os_wait_stats question

  • Hi - I am having a little think about looking into performance tuning using wait stats as one input as to what I should be looking to tune. I am going to get hold of a workload and put this against one of our test databases and have a play about.

    My question is though, that the server I will be using is also used by other people so would my wait stats possibly be skewed by this as I understand they are server wide. Is there a way to perhaps target the wait stats against a particular database?

    Thanks for any help.

  • You can't access that DMV for a particular database. Best thing you could do would be to run multiple queries against sys.dm_exec_waiting_tasks as your queries are running to determine what is causing them to wait. You can run delta's against sys.dm_os_wait_stats to see what it looked like just before you ran a test and immediately after. That can work, but you can also get extra info. Best bet, focuse on your db through sys.dm_exec_waiting_tasks.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

  • Ok thanks I will check it out. Also will try to kick as many people of as possible from test server :p

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply