SQL Server내에서
SQL Server 관련 Perfmon Counter를 읽을 수 있는 카운터인 sys.dm_os_performance_counters 읽기
WITH CTE AS
(
SELECT ROW_NUMBER() OVER (ORDER BY object_name,instance_name,counter_name) AS RN
, RTRIM(object_name) AS object_name
, RTRIM(counter_name) AS counter_name
, RTRIM(instance_name) AS instance_name
, cntr_value
, cntr_type
, CASE cntr_type
WHEN 65792 THEN '절대값 | Absolute Meaning'
WHEN 65536 THEN '절대값 | Absolute Meaning'
WHEN 272696576 THEN '초당 누적 카운터, 초기값으로부터 누적 | Per Second counter and is Cumulative in Nature'
WHEN 537003264 THEN '벌크값, 1073939712의 값으로 나누어준 후 % 연산 | Bulk Counter. To get correct value, this value needs to be divided by Base Counter value'
WHEN 1073874176 THEN '벌크값, 1073939712의 값으로 나누어준다 초당 누적 카운터, 초기값으로부터 누적 | Per Second counter and is Cumulative in Nature. To get correct value, this value needs to be divided by Base Counter value'
WHEN 1073939712 THEN '537003264의 Base Value | 537003264''s Base Counter value'
WHEN 0 THEN ' '
END AS counter_comments
FROM sys.dm_os_performance_counters
)
SELECT *
FROM CTE
ORDER BY RN
GO
References......
http://troubleshootingsql.com/2011/03/03/what-does-cntr_type-mean/
http://blogs.msdn.com/b/psssql/archive/2013/09/23/interpreting-the-counter-values-from-sys-dm-os-performance-counters.aspx
'MS SQL Server > Administration&Management' 카테고리의 다른 글
Server 레벨 계정 Role 및 권한 보기 (0) | 2015.02.02 |
---|---|
sp_job (0) | 2014.11.19 |
Impersonate 되어있는 Login의 Grantor와 Grantee 찾기 (0) | 2014.10.28 |
Execute AS 로 인한 Drop User 실패 (SQL Server Error 15136) (0) | 2014.10.21 |
XP_ReadErrorLog (0) | 2014.10.21 |