Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 

The Next Frontier of Performance Troubleshooting

By Tony Davis,

For the DBA brought up on DBCCs and the system catalog views, the number of tools for troubleshooting SQL Server performance problems has recently expanded at a dizzying rate.

Profiler has evolved into an excellent "real time" performance diagnostic tool. Dynamic Management Views (DMVs) provide a vast array of performance data on previously "closed" areas of the database engine. On top of this you have dashboard reports, RML utilities, SQLDiag, and so on, as well as any number of hand-rolled tools that crop up in blogs and articles.

Despite the unquestionable value of many of these tools, I believe that few DBAs have actually used them. It remains difficult to coax them away from "tried and trusted" stalwarts such as sysprocesses and sp_who2. Why is this? Aside from the daunting complexity of some of these tools, there is the problem of information overload. Having all of this extra data doesn't necessarily make it simpler for a DBA to pinpoint the exact cause of a performance problem. These tools all collect data at the Server, or at best database, level. With the vast array of subtly different ad-hoc SQL queries that bombard your servers and databases, having this information doesn’t seem to make it any easier to work out which queries are causing your performance problems.

Fortunately, we may be approaching the "next frontier" of performance troubleshooting. The people over at SQLCAT have just released a very nice open-source tool, called ExtendedEventsWaitstats. It consists of a set of T-SQL scripts and a set of report definition files. This project uses the Extended Events framework, supported by Waitstats event data available from the DMVs, to provide response time analysis at the session or statement level. It enables you to see the time spent in serving the user requests and the time spent in waiting for resources

It's tempting to dismiss it as just Yet Another Performance Profiling technique, but I really believe this one is different. It is based on the simple, but elegant, formula:

Response time = service time + wait time

By collecting Waitstats data at the session level, you can find out exactly how much time each session spends processing, and where it spends it, and exactly how much time it spends waiting for other processes to complete. This makes performance diagnosis a whole lot easier. If, for example, you find that user requests are spending significant periods of time writing to the transaction log, or waiting to write to it, then you immediately know that you need to optimize that process, as well as speed up (or remove load from) your log drives.

Although the technique has been popular for many years in Oracle (where it really is referred to as "YAPP"), it hasn’t been developed very far by Microsoft until recently. The Release of ExtendedEventsWaitstats seems to signal a welcome change towards a simple way for beleaguered DBAs to pinpoint the exact point of performance problems in SQL code.

Cheers,

Tony.

Total article views: 522 | Views in the last 30 days: 3
 
Related Articles
FORUM

Replication - Performance Problem

Performance problem

FORUM

performance problem

performance problem

FORUM

Budget Money to Spend

Help me spend my budget

FORUM

Server level trigger at Database level...

Database level trigger at server level

FORUM

performance problem with sql 2005 express ,vb6

performance problem ,studio express 2005

Tags
 
Contribute

Join the most active online SQL Server Community

SQL knowledge, delivered daily, free:

Email address:  

You make SSC a better place

As a member of SQLServerCentral, you get free access to loads of fresh content: thousands of articles and SQL scripts, a library of free eBooks, a weekly database news roundup, a great Q & A platform… And it’s our huge, buzzing community of SQL Server Professionals that makes it such a success.

Join us!

Steve Jones
Editor, SQLServerCentral.com

Already a member? Jump in:

Email address:   Password:   Remember me: Forgotten your password?
Steve Jones