﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / SQL Server 2005 / SQL Server 2005 Performance Tuning  / find % CPU from dm_os_performance_counters / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Thu, 23 May 2013 06:32:23 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: find % CPU from dm_os_performance_counters</title><link>http://www.sqlservercentral.com/Forums/Topic1357039-360-1.aspx</link><description>You can also go for a third party tool for the same purpose which will generate a comprehensive report of CPU usage disk space etc which will be helpful to improve the productivity of SQL server !!!!!</description><pubDate>Thu, 22 Nov 2012 04:45:05 GMT</pubDate><dc:creator>itsmemegamind</dc:creator></item><item><title>RE: find % CPU from dm_os_performance_counters</title><link>http://www.sqlservercentral.com/Forums/Topic1357039-360-1.aspx</link><description>Sorry this is a old post few months old. Thought I would post the answer in case anyone else ends up here due to a google search.This page has a good explanation of how to query this dmv : http://rtpsqlguy.wordpress.com/2009/08/11/sys-dm_os_performance_counters-explained/I would try something like:select perfCount.object_name, perfCount.counter_name, CASE WHEN perfBase.cntr_value = 0					THEN 0					ELSE (CAST(perfCount.cntr_value AS FLOAT) / perfBase.cntr_value) * 100		  END AS cntr_Valuefrom(select * from sys.dm_os_performance_counterswhere object_Name = 'SQLServer:Resource Pool Stats'and counter_name = 'CPU usage %' ) perfCountinner join(select * from sys.dm_os_performance_counterswhere object_Name = 'SQLServer:Resource Pool Stats'and counter_name = 'CPU usage % base') perfBaseon perfCount.Object_name = perfBase.object_name</description><pubDate>Mon, 05 Nov 2012 14:33:55 GMT</pubDate><dc:creator>crazyEmu</dc:creator></item><item><title>find % CPU from dm_os_performance_counters</title><link>http://www.sqlservercentral.com/Forums/Topic1357039-360-1.aspx</link><description>Hi ,Iam collecting a baseline report for one of the sql server instance, where i have only instance level access, dont have access to run the perfmon. Hence i collected details from the DMV - but iam getting values like 1023,2010, some times 0 , 1. How to get the correct percentage of CPU utilised by sql server from this DMV.SQLServer:Resource Pools                                                                                                   CPU usage %                                                                                                                     SELECT *  FROM [master].[sys].[dm_os_performance_counters]  WHERE  ([object_name] = 'SQLServer:Resource Pool Stats' AND [counter_name] = 'CPU usage %')and instance_name ='default'ThanksGKRISH</description><pubDate>Mon, 10 Sep 2012 15:52:06 GMT</pubDate><dc:creator>Gopi Krishnan-468302</dc:creator></item></channel></rss>