<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:evnet="http://www.mscommunities.com/rssmodule/"><channel><title>Entries tagged with counters - TechNet Edge</title><atom:link rel="self" type="application/rss+xml" href="http://edge.technet.com/tags/counters/rss/default.aspx" /><image><url>http://mschnlnine.vo.llnwd.net/d1/Dev/App_Themes/Edge/images/feedimage.png</url><title>Entries tagged with counters - TechNet Edge</title><link>http://edge.technet.com/Tags/Counters/</link></image><description>counters</description><link>http://edge.technet.com/Tags/Counters/</link><language>en-us</language><pubDate>Mon, 28 Jan 2008 14:52:32 GMT</pubDate><lastBuildDate>Mon, 28 Jan 2008 14:52:32 GMT</lastBuildDate><generator>EvNet (EvNet, Version=1.0.3531.14011, Culture=neutral, PublicKeyToken=null)</generator><item><title>Performance Monitoring with SQL Server 2008</title><description>&lt;img src="http://edge.technet.com/Link/982890bf-3a74-4c53-a70b-b21501cc46f5/" border="0" /&gt;Since enterprise data keeps exploding and growing both in terms of size and complexity it is important that we give consistency and predictability as far as performance is concerned from data access is concerned. With SQL Server 2008 there are a number of features one might want to use to collect, analyze, monitor and report performance related data. In this blog post we will not be able to cover all the aspects but I will try to give some of the interesting ones from the good old system monitoring counters that have been added as part of this release of SQL Server. &lt;br /&gt;
&lt;br /&gt;
&lt;strong&gt;A quick glance!!!&lt;/strong&gt;&lt;br /&gt;
As I said, SQL Server 2008 is equally loaded for performance collection, monitoring and reporting. One of the important features not to be missed is “SQL Server Performance Studio” – Data Collector feature. The version 1.0 which was basic yet powerful was a project I saw over codeplex called DMVStats (&lt;a href="http://www.codeplex.com/sqldmvstats"&gt;http://www.codeplex.com/sqldmvstats&lt;/a&gt;). But must admit this one takes the whole experience to the next level and with UI, Automation and standard reporting this is simply an awesome feature. DBA’s dreams come true!!!&lt;br /&gt;
&lt;br /&gt;
And the usual old-timers of SQL Server profiler, Database Engine Tuning Advisor, SQL Server Management Studio Reports and the SQL Server Management Packs still exist and are available to you. We will talk on those features maybe on a different post some other day.&lt;br /&gt;
&lt;br /&gt;
&lt;strong&gt;PerfMon - back on track!!!&lt;/strong&gt;&lt;br /&gt;
In a SQL Performance case, PerfMon is typically used to performance system-level bottleneck analysis.  It is important to do this type of analysis near the beginning of troubleshooting; for example, if you don't know whether the primary bottleneck on the system is disk or CPU, how do you know whether to focus on Query A (the most expensive query in terms of CPU) or Query B (the most expensive in terms if I/O)? Hence from a getting started to performance monitoring the tool to look forward is the good old PerfMon Tool.&lt;br /&gt;
&lt;br /&gt;
There are tons and tons of these counters available also on SQL Server 2005 version on various buckets like DB Engine related (Access methods, backup, buffer, CLR, cursor, mirroring, stats, locks, transactions etc), Service Broker related, Agent related, replication related, RS related, IS related, HTTP Endpoint related and so on. Getting into each and every of these is a herculean task and might not fit inside this single article. I did write some basic counter descriptions that you can take a look at: &lt;a href="http://blogs.sqlxml.org/vinodkumar/archive/2008/01/17/sql-counters-series-1-aggregated.aspx"&gt;http://blogs.sqlxml.org/vinodkumar/archive/2008/01/17/sql-counters-series-1-aggregated.aspx&lt;/a&gt; &lt;br /&gt;
&lt;br /&gt;
Moving onto SQL Server 2008 specific there are some new counters that get introduced with certain features like Resource Governor. These features are exciting and open new options to developers and administrators when working with SQL Server.&lt;br /&gt;
Resource Governor (RG) introduces a whole new concept of Resource Pools (&lt;a href="http://msdn2.microsoft.com/en-us/library/bb934084(SQL.100).aspx"&gt;http://msdn2.microsoft.com/en-us/library/bb934084(SQL.100).aspx&lt;/a&gt;) and Workload groups and we have monitors for the same under separate counters set. Let me outline both:&lt;br /&gt;
&lt;br /&gt;
&lt;table cellspacing="0" cellpadding="0"&gt;
    
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Counter&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;b&gt;&lt;span&gt;&lt;span&gt; &lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Description&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Active memory grant amount (KB)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Total granted memory to the pool workers&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Active memory Grant count&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Count of memory grants that assigned to pool workers&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Cache memory target (KB)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Current memory target for cache memory&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Compile memory target (KB)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Current memory target for compile memory&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;CPU control effect %&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;The affect of the resource governor controls calculated as (CPU usage %) / (CPU usage % without RG)&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;CPU Usage %&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;CPU Usage by the active workers in the pool &lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;CPU Usage Target %&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;The target CPU usage for the pool base on the pool configuration setting and the current activity on the SQL Server&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Max Memory (KB)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Maximum memory the pool can have&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Memory grant timeouts/sec&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Actual timeouts for pool workers waiting for memory grants&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Memory grants/sec&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Current memory grants for workers in the pool&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Pending memory grant count&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Memory grant attempts waiting for a grant or to timeout&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Query execution memory target (KB)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Memory broker target for query execution memory&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Target memory (KB)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;The target memory the pool is attempting to obtain&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Used memory (KB)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Amount of memory used by the selected pool&lt;/span&gt;&lt;/span&gt; &lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
    
&lt;/table&gt;
&lt;br /&gt;
As you can see that RG is all about throttling the Memory and CPU requirements for different workloads. And hence each of these counters can be used to drill into specific instances if required. Now moving to the next concept of Workload groups and what counters were introduced in them:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;strong&gt;
&lt;table cellspacing="0" cellpadding="0"&gt;
    
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Counter&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;b&gt;&lt;span&gt;&lt;span&gt; &lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Description&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Active parallel threads&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;The number of parallel threads in use by the workers in the group&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Active requests&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;The number of active requests for the group&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Blocked tasks&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Number of tasks in this group that are currently blocked&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;CPU usage %&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;The current amount of CPU used by the requests in the group&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Max request CPU time (ms)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Maximum amount of CPU time used by a request in the group&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Max request memory grant (KB)&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Maximum memory grant used by a request in the group&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Query optimizations/sec&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Number of query optimizations per second for the group&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Queued requests&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Number of queued requests for the group&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Requests completed/sec&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Rate of request completions for the group&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Reduced memory grant/sec&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Rate of memory grant reductions&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;b&gt;&lt;span&gt;Suboptimal plans/sec&lt;/span&gt;&lt;/b&gt; &lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
            &lt;/td&gt;
            &lt;td&gt;
            &lt;p&gt;&lt;span&gt;&lt;span&gt;Rate of suboptimal plans selected for the group&lt;/span&gt;&lt;/span&gt; &lt;/p&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
    
&lt;/table&gt;
&lt;br /&gt;
DMVs are still alive&lt;/strong&gt;&lt;br /&gt;
&lt;br /&gt;
As I said before, PerfMon really does give some great insights but to get closer to the problem statement or to get the general health of the server – DMVs give you better insight. Just to give you an insight, if you were to collect the Top 100 queries based on the time for DistributionDB reads/writes during replication - you can use the following query:&lt;br /&gt;
&lt;br /&gt;
SELECT TOP 100 st.text, qp.query_plan, qs.*  &lt;br /&gt;
FROM &lt;em&gt;sys.dm_exec_query_stats&lt;/em&gt; as qs  &lt;br /&gt;
CROSS APPLY &lt;em&gt;sys.dm_exec_sql_text(qs.sql_handle)&lt;/em&gt; as st &lt;br /&gt;
CROSS APPLY &lt;em&gt;sys.dm_exec_query_plan(qs.plan_handle)&lt;/em&gt; as qp &lt;br /&gt;
WHERE st.text like '%distribution%' &lt;br /&gt;
ORDER BY qs.total_worker_time DESC &lt;br /&gt;
GO&lt;br /&gt;
&lt;br /&gt;
This is really powerful and you can get more details by changing the where clauses like %MSmerge% for Merge replication tables, %sp_MSupd% for Distribution Agent updates on subscriber,  %sp_MSins% for Distribution Agent inserts on subscriber or removing the where clause gives you the top 100 queries based on time consumed. These are the typical statements the SQL Server Management Studio Reports use behind the scenes to get you the jazzy reports.&lt;br /&gt;
&lt;br /&gt;
Hope you enjoyed the post as much as I enjoyed writing the same. Catch more of me on my webspace at: &lt;a href="http://www.ExtremeExperts.com"&gt;www.ExtremeExperts.com&lt;/a&gt; and blog at: &lt;a href="http://blogs.sqlxml.org/vinodkumar"&gt;http://blogs.sqlxml.org/vinodkumar&lt;/a&gt;.&lt;img src="http://edge.technet.com/511/WebViewBug.aspx?EVT=0" height="1" width="1" alt="" /&gt;</description><comments>http://edge.technet.com/Media/Performance-Monitoring-with-SQL-Server-2008/</comments><link>http://edge.technet.com/Media/Performance-Monitoring-with-SQL-Server-2008/</link><pubDate>Tue, 29 Jan 2008 08:12:00 GMT</pubDate><guid isPermaLink="false">http://edge.technet.com/Media/Performance-Monitoring-with-SQL-Server-2008/</guid><evnet:views>6946</evnet:views><evnet:viewtrackingurl>http://edge.technet.com/511/WebViewBug.aspx?EVT=0</evnet:viewtrackingurl><evnet:previewtext>Since enterprise data keeps exploding and growing both in terms of size and complexity it is important that we give consistency and predictability as far as performance is concerned from data access is concerned. With SQL Server 2008 there are a number of features one might want to use to collect, analyze, monitor and report performance related data. In this blog post we will not be able to cover all the aspects but I will try to give some of the interesting ones from the good old system monitoring counters that have been added as part of this release of SQL Server. &lt;br /&gt;
&lt;br /&gt;
&lt;strong&gt;A quick glance!!!&lt;br /&gt;
&lt;/strong&gt;As I said, SQL Server 2008 is equally loaded for performance collection, monitoring and reporting. One of the important features not to be missed is “SQL Server Performance Studio” – Data Collector feature. The version 1.0 which was basic yet powerful was a project I saw over codeplex called DMVStats (&lt;a href="http://www.codeplex.com/sqldmvstats"&gt;http://www.codeplex.com/sqldmvstats&lt;/a&gt;). But must admit this one takes the whole experience to the next level and with UI, Automation and standard reporting this is simply an awesome feature. DBA’s dreams come true!!!And the usual old-timers of SQL Server profiler, Database Engine Tuning Advisor, SQL Server Management Studio Reports and the SQL Server Management Packs still exist and are available to you. We will talk on those features maybe on a different post some other day.</evnet:previewtext><media:thumbnail url="http://edge.technet.com/Link/d24f45ae-1b08-4ad1-875d-0dcaaaba0a88/" height="240" width="320" /><media:thumbnail url="http://edge.technet.com/Link/982890bf-3a74-4c53-a70b-b21501cc46f5/" height="64" width="85" /><dc:creator>Vinod_SQL</dc:creator><slash:comments>0</slash:comments><wfw:commentRss>http://edge.technet.com/Media/Performance-Monitoring-with-SQL-Server-2008/RSS/</wfw:commentRss><trackback:ping>http://edge.technet.com/511/Trackback.aspx</trackback:ping><category>Counters</category><category>PerfMon</category><category>SQL Server 2008</category></item></channel></rss>