SlideShare a Scribd company logo
1 of 51
SUP303 - Trabalhando
com DMV e DMF
Fabricio Catae – Premier Field Engineer
Ioannis Xylaras – Premier Field Engineer
Microsoft Corporate
01.
02.
03.
04.
05.
•
Introdução
•
Arquitetura do SQL Server
•
Storage Engine
•
Relational Engine
•
Adicionais
PREMIER FIELD ENGINEER
•
Suporte Global 24x7
•
Atendimento a contratos Premier Support
•
Especialista de produto
•
Tipos de Serviços
 Resolução de problemas
 Análise proativa de ambientes críticos
 Workshops e Transferência de conhecimento
MOTIVAÇÃO
•
Objetivo
 Utilizar DMV no dia a dia
•
Vantagens
 Nova ferramenta disponível no SQL 2005
 Revela detalhes sobre o funcionamento do servidor
 Executa tarefas que não são possíveis no SQL 2000
DYNAMIC MANAGEMENT OBJECTS
•
Dynamic Management Objects
 Dynamic Management Views (DMV)
 Dynamic Management Functions (DMF)
•
Características
 Somente para leitura
 Informação em memória
 Capturas instantâneas (snapshot)
CONSULTAS A DMV/DMF
•
Informações internas do SQL Server
TRABALHANDO COM DMV E DMF
•
Dynamic Management Objects
 Schema: sys
 Nome: dm_*
•
Exemplos:
SELECT * FROM sys.dm_exec_requests
SELECT * FROM sys.dm_exec_sessions
SELECT * FROM sys.dm_exec_connections
SELECT * FROM sys.dm_exec_sql_text(@h)
GRUPOS FUNCIONAIS
•
DMV/DMF estão organizados em categorias
 Common Language Runtime (CLR)
 Database Mirroring
 Database
 Execution
 Indexes
 I/O Operations
 Query Notifications
 Replication
 Service Broker
 SQL Server Operating System
 Transaction
DEMO
•
Select * from sys.system_objects
Where name like ‘dm_%’
•
Books Online 2005
 “Dynamic Management Objects”
 “sys.dm_exec_requests”
ARQUITETURA DO SQL SERVER
•
Storage Engine
 Infra-estrutura do SQL Server
 Comunicação com o Sistema Operacional
 Exemplos:
 Gerenciamento de Threads
 Gerenciamento de Memória
 Gerenciamento de I/O
•
Relational Engine
 Implementação da linguagem SQL
 Conceito de índices e estatísticas
 Exemplos:
 Compilação
 Otimização
 Execução da query
STORAGE ENGINE
•
Infra-estrutura do SQL Server
 Thread
 Memória
 I/O
THREADS
-
Threads
-
Worker Threads
-
Tasks
Task
Threads
Worker Threads
TASK / TAREFAS
•
Running, Runnable, Suspended
Task
Task
Task
Task
Task
Task
RUNNING
RUNNABLE
SUSPENDED
100% CPU
•
sys.dm_os_tasks
 task_state
 RUNNING
 RUNNABLE
Worker Task
Worker Task
Worker Task
Worker Task
DEMOSNome:
Título:
•
Fabricio Catae
•
DMV’s
SUSPENDED
•
Tarefas Bloqueadas
 Disco
 Rede
 Linked Server
•
sys.dm_os_waiting_tasks
 session_id
 wait_type
 wait_duration_ms
 resource_description
 blocking_session_id
DISK I/O
•
Tarefas Bloqueadas
 Data Files: PAGEIOLATCH
 Log Files: WRITELOG
•
sys.dm_io_virtual_file_stats
 database_id
 file_id
 num_of_reads
 num_of_writes
 num_of_bytes_read
 num_of_bytes_written
NG
Auth
Sidep
AC
MM
DEMOSNome:
Título:
•
Fabricio Catae
•
DMV’s
GERENCIAMENTO DE MEMÓRIA
•
Módulo Reescrito para SQL 2005
 Memory Nodes
 Memory Clerks
 Cache e User Stores
 Page Allocators
DM_OS_MEMORY_*
•
dm_os_memory_clerks
•
User e Cache Stores
 dm_os_memory_cache_counters
 dm_os_memory_cache_hash_tables
 dm_os_memory_cache_clock
 dm_os_memory_cache_entries
•
Object Stores
 dm_os_memory_pools
DEMOSNome:
Título:
•
Fabricio Catae
•
DMV’s
RELATIONAL ENGINE
•
Execução de Query
•
Histórico de Execução
•
Utilização de Índices
EXECUÇÃO DE QUERY
-
session_id
-
sql_handle
- plan_handle
-
estatísticas
- cpu
- memória
- i/o
- duração
Session
Connection
Request
Request
Request
REQUEST DMV
•
DMV
 sys.dm_exec_connections
 sys.dm_exec_sessions
 sys.dm_exec_requests
•
DMF
 sys.dm_exec_connections( sql_handle )
 sys.dm_exec_connections( plan_handle )
DEMO
•
Cenário: 100% CPU
•
Select * from sys.dm_exec_connections
•
Select * from sys.dm_exec_sessions
•
Select * from sys.dm_exec_requests
•
Select * from sys.dm_exec_sql_text(@h)
•
Use substring
•
Select * from sys.dm_exec_requests
•
CROSS APPLY operator
•
Select * from sys.dm_exec_plan_handle(@h)
•
Save query plan to with sqlplan file extension
HISTÓRICO DE EXECUÇÃO
•
Após cada execução, essa DMV é atualizada
•
Colunas
 sql_handle
 plan_generation_num
 plan_handle
 last_execution
 execution_count
 total_worker_time
 total_physical_read/write
 total_logical_read/write
 total_elapsed_time
SQL_HANDLE
•
sys.dm_exec_sql_text( @handle )
NÚMERO DE EXECUÇÕES
•
Execution_count
TEMPO DE CPU UTILIZADO (MS)
•
Total_worker_time
TEMPO TOTAL GASTO (MS)
•
Total_elapsed_time
DM_EXEC_QUERY_STATS
•
Algumas queries não aparecem
 Extended Stored Procedures
 .NET Stored Procedures
 Comandos T-SQL (IF, WHILE, etc)
 Queries triviais
•
Existem situações que removem parte das estatísticas
 DBCC FREEPROCCACHE
 Memory Pressure
DEMO
•
Cenário: I/O intensive
•
Verificar que não há problemas
•
SELECT * FROM sys.dm_exec_requests
•
Listar todas as queries de sys.dm_exec_query_stats
•
Identificar os consumidores de CPU
•
Identificar os responsáveis pelos physical read
•
Calcular a média de leituras físicas
•
Utilizar sql_handle e plan_handle
ÍNDICES
•
Falta de índices adequados para queries
 sys.dm_db_missing_index_details
•
Utilização de Índices
 sys.dm_db_index_usage_stats
DEMOSNome:
Título:
•
Ioannis Xylaras
•
DMV’s
ADICIONAIS
•
Server level
 dm_exec_*
 Execution of user code and associated connections
 dm_os_*
 low level system (server-wide) info such as memory, locking &
scheduling
 dm_tran_*
 Transactions & isolation
 dm_io_*
 Input/Output on network and disks
 dm_db_*
 Databases and database objects
•
GRUPO DE DMV’S
ADICIONAIS
•
Component level
 dm_repl_*
 Replication
 dm_broker_*
 SQL Service Broker
 dm_fts_*
 Full Text Search
 dm_qn_*
 Query Notifications
•
GRUPO DE DMV’S
ADICIONAIS
•
MEMÓRIA ALOCADA
•
Você pode usar o sys.dm_os_memory_clerks DMV como
exemplo a seguir para identificar quanta memória o SQL
Server aloca através do mecanismo do AWE.
•
Select
sum(awe_allocated_kb) / 1024 as [AWE allocated, Mb] from
sys.dm_os_memory_clerks
•
•
CENÁRIO DE PERFORMANCE
ADICIONAIS
•
Query plan ineficiente
•
A query sys.dm_exec_query_stats é um eficiente caminho
para determinar qual query está usando a maior CPU
cumulativa.
•
Select
•
highest_cpu_queries.plan_handle,
•
highest_cpu_queries.total_worker_time,
•
q.dbid, q.objectid, q.number, q.encrypted, q.[text]
•
from
•
(select top 50 qs.plan_handle, qs.total_worker_time
•
from sys.dm_exec_query_statssys.dm_exec_query_stats qs
•
order by qs.total_worker_time desc) as highest_cpu_queries
•
cross apply sys.dm_exec_sql_text(plan_handle) as q
•
order by highest_cpu_queries.total_worker_time desc
•
CENÁRIO DE PERFORMANCE
ADICIONAIS
•
Top CPUs procs & batches
Select top 50
•
sum(qs.total_worker_time) as total_cpu_time,
•
sum(qs.execution_count) as total_execution_count,
•
count(*) as '#_statements',
•
qt.dbid, qt.objectid, qs.sql_handle,
•
qt.[text] from sys.dm_exec_query_stats as qs
•
cross apply sys.dm_exec_sql_text (qs.sql_handle) as qt
•
group by qt.dbid,qt.objectid, qs.sql_handle,qt.[text]
•
order by sum(qs.total_worker_time) desc,qs.sql_handle
•
CENÁRIO DE PERFORMANCE
ADICIONAIS
•
CPU – O que está executando em paralelo?
•
Paralelismo é bom para DW, não para OLTP
Select r.session_id,
r.request_id,
max(isnull(exec_context_id, 0)) as number_of_workers,
r.sql_handle,
r.statement_start_offset,
r.statement_end_offset,
r.plan_handle
from sys.dm_exec_requestssys.dm_exec_requests r
join sys.dm_os_tasks t on r.session_id = t.session_id
join sys.dm_exec_sessions s on r.session_id = s.session_id
where s.is_user_process = 0x1
group by r.session_id, r.request_id, r.sql_handle, r.plan_handle,
r.statement_start_offset, r.statement_end_offset
having max(isnull(exec_context_id, 0)) > 0
•
CENÁRIO DE PERFORMANCE
ADICIONAIS
•
Pressão CPU : Recompilação
•
Select top 25
•
sql_text.text,
•
sql_handle,
•
plan_generation_num,
•
execution_count,
•
dbid,
•
objectid
•
from sys.dm_exec_query_statssys.dm_exec_query_stats a
•
Cross apply sys.dm_exec_sql_text(sql_handle) as sql_text
•
where plan_generation_num >1
•
order by plan_generation_num desc
•
CENÁRIO DE PERFORMANCE
ADICIONAIS
•
Memória: Top memory por objeto & índice
•
CENÁRIO DE PERFORMANCE
Select b.database_id
,p.object_id
,object_name(p.object_id) as objname
,p.index_id
,buffer_count=count(*)
from sys.allocation_units a,
sys.dm_os_buffer_descriptorssys.dm_os_buffer_descriptors b,
sys.partitions p
where a.allocation_unit_id =
b.allocation_unit_id
and a.container_id = p.hobt_id
group by b.database_id,p.object_id,
p.index_id
order by buffer_count desc
ADICIONAIS
•
Top IOs por statement
•
SELECT TOP 50
•
(qs.total_logical_reads + qs.total_logical_writes) /qs.execution_count
•
as [Avg IO],
•
substring (qt.text,qs.statement_start_offset/2, (case when
qs.statement_end_offset = -1
•
then len(convert(nvarchar(max), qt.text)) * 2
•
else qs.statement_end_offset end -qs.statement_start_offset)/2)
•
as query_text,
•
qt.dbid,
•
qt.objectid
•
FROM sys.dm_exec_query_statssys.dm_exec_query_stats qs
•
cross apply sys.dm_exec_sql_text (qs.sql_handle) as qt
•
ORDER BY
•
[Avg IO] DESC
•
CENÁRIO DE PERFORMANCE
ADICIONAIS
•
Visualizando a utilização dos índices das tabelas
•
Select so.name AS 'Table Name', si.name AS 'index Name',
si.type_desc AS 'Index Type', si.index_id AS 'Index ID',
us.user_seeks, us.user_scans, us.system_seeks, us.system_scans
FROM sys.dm_db_index_usage_statssys.dm_db_index_usage_stats us
INNER JOIN sys.objects so
ON us.object_id = so.object_id
INNER JOIN sys.indexes si
ON so.object_id = si.object_id
WHERE so.type = 'U'
•
CENÁRIO DE PERFORMANCE
ADICIONAIS
•
Visualizando Índices não atualmente utilizados
Select so.name AS 'Table Name', si.name AS 'index Name',
si.type_desc AS 'Index Type', si.index_id AS 'Index ID',
•
us.user_seeks, us.user_scans, us.system_seeks, us.system_scans,
us.user_lookups, us.system_lookups,us.user_updates,
•
us.system_updates
•
--other columns are available
•
FROM sys.dm_db_index_usage_statssys.dm_db_index_usage_stats us
•
INNER JOIN sys.objects so ON us.object_id = so.object_id
•
INNER JOIN sys.indexes si ON so.object_id = si.object_id
•
WHERE so.type = 'U' AND us.user_seeks = 0
•
AND us.user_scans = 0 AND us.system_seeks = 0
•
AND us.system_scans = 0
•
CENÁRIO DE PERFORMANCE
PRÓXIMAS PALESTRAS
PRÓXIMAS
PALESTRAS
Palestra 1:
Palestra 2:
Palestra 3:
•
SUP304 Otimizando os Subsistemas
de Discos para o Microsoft Exchange
Server
30/11/2006 15:30 - 16:45
•
SUP305 Processo de Migração para
ISA Server 2006
30/11/2006 17:00 - 18:15
•
Ask the Experts
LINKS ÚTEIS
SQL Server 2005 System Views Online
http://download.microsoft.com/download/0/d/f/0df
e488e-a335-4480-8a8a-
b405e32f4368/SQL2005_Sys_Views.pdf
Troubleshooting Performance
Problems in SQL 2005
http://www.microsoft.com/technet/prodtechn
ol/sql/2005/tsprfprb.mspx
SQL Server 2005 Books Online
http://www.microsoft.com/technet/prodtechn
ol/sql/2005/downloads/books.mspx
Dynamic Management Views and
Functions
http://msdn2.microsoft.com/en-
us/library/ms188754.aspx
LINKS ÚTEIS
Technet Brasil
http://www.microsoft.com/brasil/technet
http://www.microsoft.com/brasil/technet/comunid
ade/default.mspx
http://forums.microsoft.com/technet-br
Certificações Microsoft
http://www.microsoft.com/brasil/certifique
http://www.microsoft.com/learning
Slava Oks Blog
http://blogs.msdn.com/slavao
Microsoft Most Valuable Professional
http://mvp.support.microsoft.com/
PERGUNTAS E RESPOSTAS
•
Fabricio Catae
Ioannis Xylaras
••
Microsoft Corporate
TechEd 2006: Trabalhando com DMV e DMF

More Related Content

Viewers also liked

2 bill intl trend in pfm reforms
2 bill intl trend in pfm reforms2 bill intl trend in pfm reforms
2 bill intl trend in pfm reformssurardi12
 
Microsoft Certified Master (Comunidade MCM)
Microsoft Certified Master (Comunidade MCM)Microsoft Certified Master (Comunidade MCM)
Microsoft Certified Master (Comunidade MCM)Fabrício Catae
 
Como funciona um banco de dados? (Prudente TechDay 2010)
Como funciona um banco de dados? (Prudente TechDay 2010)Como funciona um banco de dados? (Prudente TechDay 2010)
Como funciona um banco de dados? (Prudente TechDay 2010)Fabrício Catae
 
Kodu Game Lab (GX Brasil 2015)
Kodu Game Lab (GX Brasil 2015)Kodu Game Lab (GX Brasil 2015)
Kodu Game Lab (GX Brasil 2015)Fabrício Catae
 
Busca de Documentos (Marilia TechDay 2011)
Busca de Documentos (Marilia TechDay 2011)Busca de Documentos (Marilia TechDay 2011)
Busca de Documentos (Marilia TechDay 2011)Fabrício Catae
 
Inside SQL Server: Como funciona um banco de dados?
Inside SQL Server: Como funciona um banco de dados?Inside SQL Server: Como funciona um banco de dados?
Inside SQL Server: Como funciona um banco de dados?Fabrício Catae
 
Capítulo 11 alfredo prieto abp 4x4 en laboratorios de prác…
Capítulo 11 alfredo prieto abp 4x4 en laboratorios de prác…Capítulo 11 alfredo prieto abp 4x4 en laboratorios de prác…
Capítulo 11 alfredo prieto abp 4x4 en laboratorios de prác…Alfredo Prieto Martín
 
ハイブリッドアプリ開発最前線から見たHtml5の理想と現実
ハイブリッドアプリ開発最前線から見たHtml5の理想と現実ハイブリッドアプリ開発最前線から見たHtml5の理想と現実
ハイブリッドアプリ開発最前線から見たHtml5の理想と現実Monaca
 
JavaScriptによるvideo audio要素のコントロール入門
JavaScriptによるvideo audio要素のコントロール入門JavaScriptによるvideo audio要素のコントロール入門
JavaScriptによるvideo audio要素のコントロール入門Yossy Taka
 
JavaScript04 jquery プラグインを使おう
JavaScript04 jquery プラグインを使おうJavaScript04 jquery プラグインを使おう
JavaScript04 jquery プラグインを使おうYossy Taka
 
Energy resource management
Energy resource managementEnergy resource management
Energy resource managementRiddhima Kartik
 
Cognitive Discourse Analysis: Introduction (LANCOM 1)
Cognitive Discourse Analysis: Introduction (LANCOM 1) Cognitive Discourse Analysis: Introduction (LANCOM 1)
Cognitive Discourse Analysis: Introduction (LANCOM 1) Jelec Anna
 
マンガ駆動開発で始める 、初めてのUXデザインプロセス  マンガ駆動開発 第4版
マンガ駆動開発で始める、初めてのUXデザインプロセス マンガ駆動開発 第4版マンガ駆動開発で始める、初めてのUXデザインプロセス マンガ駆動開発 第4版
マンガ駆動開発で始める 、初めてのUXデザインプロセス  マンガ駆動開発 第4版Koji Hara
 
Conceitos e arquitetura do sistema de banco de dados
Conceitos e arquitetura do sistema de banco de dadosConceitos e arquitetura do sistema de banco de dados
Conceitos e arquitetura do sistema de banco de dadosElaine Cecília Gatto
 
Ajax非同期通信によるサーバー通信
Ajax非同期通信によるサーバー通信Ajax非同期通信によるサーバー通信
Ajax非同期通信によるサーバー通信Yossy Taka
 
JavaScriptによるgoogle maps apiの使い方
JavaScriptによるgoogle maps apiの使い方JavaScriptによるgoogle maps apiの使い方
JavaScriptによるgoogle maps apiの使い方Yossy Taka
 
WebデザイナのためのjQuery入門。
WebデザイナのためのjQuery入門。WebデザイナのためのjQuery入門。
WebデザイナのためのjQuery入門。Yossy Taka
 

Viewers also liked (19)

2 bill intl trend in pfm reforms
2 bill intl trend in pfm reforms2 bill intl trend in pfm reforms
2 bill intl trend in pfm reforms
 
Microsoft Certified Master (Comunidade MCM)
Microsoft Certified Master (Comunidade MCM)Microsoft Certified Master (Comunidade MCM)
Microsoft Certified Master (Comunidade MCM)
 
Como funciona um banco de dados? (Prudente TechDay 2010)
Como funciona um banco de dados? (Prudente TechDay 2010)Como funciona um banco de dados? (Prudente TechDay 2010)
Como funciona um banco de dados? (Prudente TechDay 2010)
 
Kodu Game Lab (GX Brasil 2015)
Kodu Game Lab (GX Brasil 2015)Kodu Game Lab (GX Brasil 2015)
Kodu Game Lab (GX Brasil 2015)
 
4. factores f y p
4. factores f y p4. factores f y p
4. factores f y p
 
Busca de Documentos (Marilia TechDay 2011)
Busca de Documentos (Marilia TechDay 2011)Busca de Documentos (Marilia TechDay 2011)
Busca de Documentos (Marilia TechDay 2011)
 
Inside SQL Server: Como funciona um banco de dados?
Inside SQL Server: Como funciona um banco de dados?Inside SQL Server: Como funciona um banco de dados?
Inside SQL Server: Como funciona um banco de dados?
 
Capítulo 11 alfredo prieto abp 4x4 en laboratorios de prác…
Capítulo 11 alfredo prieto abp 4x4 en laboratorios de prác…Capítulo 11 alfredo prieto abp 4x4 en laboratorios de prác…
Capítulo 11 alfredo prieto abp 4x4 en laboratorios de prác…
 
GPU Design on FPGA
GPU Design on FPGAGPU Design on FPGA
GPU Design on FPGA
 
ハイブリッドアプリ開発最前線から見たHtml5の理想と現実
ハイブリッドアプリ開発最前線から見たHtml5の理想と現実ハイブリッドアプリ開発最前線から見たHtml5の理想と現実
ハイブリッドアプリ開発最前線から見たHtml5の理想と現実
 
JavaScriptによるvideo audio要素のコントロール入門
JavaScriptによるvideo audio要素のコントロール入門JavaScriptによるvideo audio要素のコントロール入門
JavaScriptによるvideo audio要素のコントロール入門
 
JavaScript04 jquery プラグインを使おう
JavaScript04 jquery プラグインを使おうJavaScript04 jquery プラグインを使おう
JavaScript04 jquery プラグインを使おう
 
Energy resource management
Energy resource managementEnergy resource management
Energy resource management
 
Cognitive Discourse Analysis: Introduction (LANCOM 1)
Cognitive Discourse Analysis: Introduction (LANCOM 1) Cognitive Discourse Analysis: Introduction (LANCOM 1)
Cognitive Discourse Analysis: Introduction (LANCOM 1)
 
マンガ駆動開発で始める 、初めてのUXデザインプロセス  マンガ駆動開発 第4版
マンガ駆動開発で始める、初めてのUXデザインプロセス マンガ駆動開発 第4版マンガ駆動開発で始める、初めてのUXデザインプロセス マンガ駆動開発 第4版
マンガ駆動開発で始める 、初めてのUXデザインプロセス  マンガ駆動開発 第4版
 
Conceitos e arquitetura do sistema de banco de dados
Conceitos e arquitetura do sistema de banco de dadosConceitos e arquitetura do sistema de banco de dados
Conceitos e arquitetura do sistema de banco de dados
 
Ajax非同期通信によるサーバー通信
Ajax非同期通信によるサーバー通信Ajax非同期通信によるサーバー通信
Ajax非同期通信によるサーバー通信
 
JavaScriptによるgoogle maps apiの使い方
JavaScriptによるgoogle maps apiの使い方JavaScriptによるgoogle maps apiの使い方
JavaScriptによるgoogle maps apiの使い方
 
WebデザイナのためのjQuery入門。
WebデザイナのためのjQuery入門。WebデザイナのためのjQuery入門。
WebデザイナのためのjQuery入門。
 

Similar to TechEd 2006: Trabalhando com DMV e DMF

SQL Explore 2012: P&T Part 1
SQL Explore 2012: P&T Part 1SQL Explore 2012: P&T Part 1
SQL Explore 2012: P&T Part 1sqlserver.co.il
 
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAsOracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAsZohar Elkayam
 
SQL Server Performance Analysis
SQL Server Performance AnalysisSQL Server Performance Analysis
SQL Server Performance AnalysisEduardo Castro
 
SQL Server Admin Best Practices with DMV's
SQL Server Admin Best Practices with DMV'sSQL Server Admin Best Practices with DMV's
SQL Server Admin Best Practices with DMV'sSparkhound Inc.
 
Microsoft SQL Server Query Tuning
Microsoft SQL Server Query TuningMicrosoft SQL Server Query Tuning
Microsoft SQL Server Query TuningMark Ginnebaugh
 
Performance Schema for MySQL Troubleshooting
Performance Schema for MySQL TroubleshootingPerformance Schema for MySQL Troubleshooting
Performance Schema for MySQL TroubleshootingSveta Smirnova
 
Kåre Rude Andersen - Be a hero – optimize scom and present your services
Kåre Rude Andersen - Be a hero – optimize scom and present your servicesKåre Rude Andersen - Be a hero – optimize scom and present your services
Kåre Rude Andersen - Be a hero – optimize scom and present your servicesNordic Infrastructure Conference
 
6 tips for improving ruby performance
6 tips for improving ruby performance6 tips for improving ruby performance
6 tips for improving ruby performanceEngine Yard
 
Investigate SQL Server Memory Like Sherlock Holmes
Investigate SQL Server Memory Like Sherlock HolmesInvestigate SQL Server Memory Like Sherlock Holmes
Investigate SQL Server Memory Like Sherlock HolmesRichard Douglas
 
SQL Server 2022 Programmability & Performance
SQL Server 2022 Programmability & PerformanceSQL Server 2022 Programmability & Performance
SQL Server 2022 Programmability & PerformanceGianluca Hotz
 
Performance Analysis: new tools and concepts from the cloud
Performance Analysis: new tools and concepts from the cloudPerformance Analysis: new tools and concepts from the cloud
Performance Analysis: new tools and concepts from the cloudBrendan Gregg
 
SQL Server 2016: Just a Few of Our DBA's Favorite Things
SQL Server 2016: Just a Few of Our DBA's Favorite ThingsSQL Server 2016: Just a Few of Our DBA's Favorite Things
SQL Server 2016: Just a Few of Our DBA's Favorite ThingsHostway|HOSTING
 
2013 Collaborate - OAUG - Presentation
2013 Collaborate - OAUG - Presentation2013 Collaborate - OAUG - Presentation
2013 Collaborate - OAUG - PresentationBiju Thomas
 
Performance & Scalability Improvements in Perforce
Performance & Scalability Improvements in PerforcePerformance & Scalability Improvements in Perforce
Performance & Scalability Improvements in PerforcePerforce
 
22-4_PerformanceTuningUsingtheAdvisorFramework.pdf
22-4_PerformanceTuningUsingtheAdvisorFramework.pdf22-4_PerformanceTuningUsingtheAdvisorFramework.pdf
22-4_PerformanceTuningUsingtheAdvisorFramework.pdfyishengxi
 
SQL Server - Using Tools to Analyze Query Performance
SQL Server - Using Tools to Analyze Query PerformanceSQL Server - Using Tools to Analyze Query Performance
SQL Server - Using Tools to Analyze Query PerformanceMarek Maśko
 

Similar to TechEd 2006: Trabalhando com DMV e DMF (20)

SQL Explore 2012: P&T Part 1
SQL Explore 2012: P&T Part 1SQL Explore 2012: P&T Part 1
SQL Explore 2012: P&T Part 1
 
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAsOracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAs
 
SQL Server Performance Analysis
SQL Server Performance AnalysisSQL Server Performance Analysis
SQL Server Performance Analysis
 
SQL Server Admin Best Practices with DMV's
SQL Server Admin Best Practices with DMV'sSQL Server Admin Best Practices with DMV's
SQL Server Admin Best Practices with DMV's
 
Microsoft SQL Server Query Tuning
Microsoft SQL Server Query TuningMicrosoft SQL Server Query Tuning
Microsoft SQL Server Query Tuning
 
Performance Schema for MySQL Troubleshooting
Performance Schema for MySQL TroubleshootingPerformance Schema for MySQL Troubleshooting
Performance Schema for MySQL Troubleshooting
 
Kåre Rude Andersen - Be a hero – optimize scom and present your services
Kåre Rude Andersen - Be a hero – optimize scom and present your servicesKåre Rude Andersen - Be a hero – optimize scom and present your services
Kåre Rude Andersen - Be a hero – optimize scom and present your services
 
6 tips for improving ruby performance
6 tips for improving ruby performance6 tips for improving ruby performance
6 tips for improving ruby performance
 
Mysql tracing
Mysql tracingMysql tracing
Mysql tracing
 
Mysql tracing
Mysql tracingMysql tracing
Mysql tracing
 
Investigate SQL Server Memory Like Sherlock Holmes
Investigate SQL Server Memory Like Sherlock HolmesInvestigate SQL Server Memory Like Sherlock Holmes
Investigate SQL Server Memory Like Sherlock Holmes
 
SQL Server 2022 Programmability & Performance
SQL Server 2022 Programmability & PerformanceSQL Server 2022 Programmability & Performance
SQL Server 2022 Programmability & Performance
 
Sherlock holmes for dba’s
Sherlock holmes for dba’sSherlock holmes for dba’s
Sherlock holmes for dba’s
 
Performance Analysis: new tools and concepts from the cloud
Performance Analysis: new tools and concepts from the cloudPerformance Analysis: new tools and concepts from the cloud
Performance Analysis: new tools and concepts from the cloud
 
SQL Server 2016: Just a Few of Our DBA's Favorite Things
SQL Server 2016: Just a Few of Our DBA's Favorite ThingsSQL Server 2016: Just a Few of Our DBA's Favorite Things
SQL Server 2016: Just a Few of Our DBA's Favorite Things
 
2013 Collaborate - OAUG - Presentation
2013 Collaborate - OAUG - Presentation2013 Collaborate - OAUG - Presentation
2013 Collaborate - OAUG - Presentation
 
Performance & Scalability Improvements in Perforce
Performance & Scalability Improvements in PerforcePerformance & Scalability Improvements in Perforce
Performance & Scalability Improvements in Perforce
 
22-4_PerformanceTuningUsingtheAdvisorFramework.pdf
22-4_PerformanceTuningUsingtheAdvisorFramework.pdf22-4_PerformanceTuningUsingtheAdvisorFramework.pdf
22-4_PerformanceTuningUsingtheAdvisorFramework.pdf
 
Know your SQL Server - DMVs
Know your SQL Server - DMVsKnow your SQL Server - DMVs
Know your SQL Server - DMVs
 
SQL Server - Using Tools to Analyze Query Performance
SQL Server - Using Tools to Analyze Query PerformanceSQL Server - Using Tools to Analyze Query Performance
SQL Server - Using Tools to Analyze Query Performance
 

More from Fabrício Catae

Meetup Mule SP: Kafka (Edgar)
Meetup Mule SP: Kafka (Edgar)Meetup Mule SP: Kafka (Edgar)
Meetup Mule SP: Kafka (Edgar)Fabrício Catae
 
Build smarter and scalable applications using Microsoft Azure Database Services
Build smarter and scalable applications using Microsoft Azure Database ServicesBuild smarter and scalable applications using Microsoft Azure Database Services
Build smarter and scalable applications using Microsoft Azure Database ServicesFabrício Catae
 
Fora Hackers! Proteção em camadas do SQL Server
Fora Hackers! Proteção em camadas do SQL ServerFora Hackers! Proteção em camadas do SQL Server
Fora Hackers! Proteção em camadas do SQL ServerFabrício Catae
 
Migrando o Parse para Azure: Lições Aprendidas
Migrando o Parse para Azure: Lições AprendidasMigrando o Parse para Azure: Lições Aprendidas
Migrando o Parse para Azure: Lições AprendidasFabrício Catae
 
TechEd 2015: Diagnosticando problemas em sites ASP.NET
TechEd 2015: Diagnosticando problemas em sites ASP.NETTechEd 2015: Diagnosticando problemas em sites ASP.NET
TechEd 2015: Diagnosticando problemas em sites ASP.NETFabrício Catae
 
Estratégias de Backup e Restore
Estratégias de Backup e RestoreEstratégias de Backup e Restore
Estratégias de Backup e RestoreFabrício Catae
 
Indo para o proximo nivel: MCSM e MCA em SQL Server 2012
Indo para o proximo nivel:  MCSM e MCA em SQL Server 2012Indo para o proximo nivel:  MCSM e MCA em SQL Server 2012
Indo para o proximo nivel: MCSM e MCA em SQL Server 2012Fabrício Catae
 
CLR Fundamentals: Memory Management
CLR Fundamentals: Memory ManagementCLR Fundamentals: Memory Management
CLR Fundamentals: Memory ManagementFabrício Catae
 
TechEd 2009: Planejamento e Operação de Ambientes SharePoint Multi-Terabyte
TechEd 2009: Planejamento e Operação de Ambientes SharePoint Multi-TerabyteTechEd 2009: Planejamento e Operação de Ambientes SharePoint Multi-Terabyte
TechEd 2009: Planejamento e Operação de Ambientes SharePoint Multi-TerabyteFabrício Catae
 
TechEd 2011: Raio-X do SQL Server: Arquitetura Interna do Gerenciador de Ban...
TechEd 2011: Raio-X do SQL Server: Arquitetura Interna do Gerenciador de Ban...TechEd 2011: Raio-X do SQL Server: Arquitetura Interna do Gerenciador de Ban...
TechEd 2011: Raio-X do SQL Server: Arquitetura Interna do Gerenciador de Ban...Fabrício Catae
 
TechEd 2010: SQL Server com Foco em Diagnóstico de Desempenho
TechEd 2010: SQL Server com Foco em Diagnóstico de DesempenhoTechEd 2010: SQL Server com Foco em Diagnóstico de Desempenho
TechEd 2010: SQL Server com Foco em Diagnóstico de DesempenhoFabrício Catae
 
TechEd 2010: Escalando aplicações OLTP:Design de aplicação e considerações pa...
TechEd 2010: Escalando aplicações OLTP:Design de aplicação e considerações pa...TechEd 2010: Escalando aplicações OLTP:Design de aplicação e considerações pa...
TechEd 2010: Escalando aplicações OLTP:Design de aplicação e considerações pa...Fabrício Catae
 
Advanced SQL Memory Management (GeekReady 2012)
Advanced SQL Memory Management (GeekReady 2012)Advanced SQL Memory Management (GeekReady 2012)
Advanced SQL Memory Management (GeekReady 2012)Fabrício Catae
 
Como funciona um banco de dados? (Worldwide Online TechDay 2010)
Como funciona um banco de dados? (Worldwide Online TechDay 2010)Como funciona um banco de dados? (Worldwide Online TechDay 2010)
Como funciona um banco de dados? (Worldwide Online TechDay 2010)Fabrício Catae
 
TechEd 2005: Novos Recursos T-SQL (SQL 2005)
TechEd 2005: Novos Recursos T-SQL (SQL 2005)TechEd 2005: Novos Recursos T-SQL (SQL 2005)
TechEd 2005: Novos Recursos T-SQL (SQL 2005)Fabrício Catae
 

More from Fabrício Catae (20)

Mule Meetup Cache Redis
Mule Meetup Cache RedisMule Meetup Cache Redis
Mule Meetup Cache Redis
 
Meetup Mule SP: Kafka (Edgar)
Meetup Mule SP: Kafka (Edgar)Meetup Mule SP: Kafka (Edgar)
Meetup Mule SP: Kafka (Edgar)
 
SQL Server on Linux
SQL Server on LinuxSQL Server on Linux
SQL Server on Linux
 
Build smarter and scalable applications using Microsoft Azure Database Services
Build smarter and scalable applications using Microsoft Azure Database ServicesBuild smarter and scalable applications using Microsoft Azure Database Services
Build smarter and scalable applications using Microsoft Azure Database Services
 
Fora Hackers! Proteção em camadas do SQL Server
Fora Hackers! Proteção em camadas do SQL ServerFora Hackers! Proteção em camadas do SQL Server
Fora Hackers! Proteção em camadas do SQL Server
 
Migrando o Parse para Azure: Lições Aprendidas
Migrando o Parse para Azure: Lições AprendidasMigrando o Parse para Azure: Lições Aprendidas
Migrando o Parse para Azure: Lições Aprendidas
 
TechEd 2015: Diagnosticando problemas em sites ASP.NET
TechEd 2015: Diagnosticando problemas em sites ASP.NETTechEd 2015: Diagnosticando problemas em sites ASP.NET
TechEd 2015: Diagnosticando problemas em sites ASP.NET
 
Estratégias de Backup e Restore
Estratégias de Backup e RestoreEstratégias de Backup e Restore
Estratégias de Backup e Restore
 
Indo para o proximo nivel: MCSM e MCA em SQL Server 2012
Indo para o proximo nivel:  MCSM e MCA em SQL Server 2012Indo para o proximo nivel:  MCSM e MCA em SQL Server 2012
Indo para o proximo nivel: MCSM e MCA em SQL Server 2012
 
CLR Fundamentals: Memory Management
CLR Fundamentals: Memory ManagementCLR Fundamentals: Memory Management
CLR Fundamentals: Memory Management
 
Learn how to debug
Learn how to debugLearn how to debug
Learn how to debug
 
TechEd 2009: Planejamento e Operação de Ambientes SharePoint Multi-Terabyte
TechEd 2009: Planejamento e Operação de Ambientes SharePoint Multi-TerabyteTechEd 2009: Planejamento e Operação de Ambientes SharePoint Multi-Terabyte
TechEd 2009: Planejamento e Operação de Ambientes SharePoint Multi-Terabyte
 
TechEd 2011: Raio-X do SQL Server: Arquitetura Interna do Gerenciador de Ban...
TechEd 2011: Raio-X do SQL Server: Arquitetura Interna do Gerenciador de Ban...TechEd 2011: Raio-X do SQL Server: Arquitetura Interna do Gerenciador de Ban...
TechEd 2011: Raio-X do SQL Server: Arquitetura Interna do Gerenciador de Ban...
 
TechEd 2010: SQL Server com Foco em Diagnóstico de Desempenho
TechEd 2010: SQL Server com Foco em Diagnóstico de DesempenhoTechEd 2010: SQL Server com Foco em Diagnóstico de Desempenho
TechEd 2010: SQL Server com Foco em Diagnóstico de Desempenho
 
TechEd 2010: Escalando aplicações OLTP:Design de aplicação e considerações pa...
TechEd 2010: Escalando aplicações OLTP:Design de aplicação e considerações pa...TechEd 2010: Escalando aplicações OLTP:Design de aplicação e considerações pa...
TechEd 2010: Escalando aplicações OLTP:Design de aplicação e considerações pa...
 
Advanced SQL Memory Management (GeekReady 2012)
Advanced SQL Memory Management (GeekReady 2012)Advanced SQL Memory Management (GeekReady 2012)
Advanced SQL Memory Management (GeekReady 2012)
 
Como funciona um banco de dados? (Worldwide Online TechDay 2010)
Como funciona um banco de dados? (Worldwide Online TechDay 2010)Como funciona um banco de dados? (Worldwide Online TechDay 2010)
Como funciona um banco de dados? (Worldwide Online TechDay 2010)
 
SQL 2005 Memory Module
SQL 2005 Memory ModuleSQL 2005 Memory Module
SQL 2005 Memory Module
 
TechEd 2005: Novos Recursos T-SQL (SQL 2005)
TechEd 2005: Novos Recursos T-SQL (SQL 2005)TechEd 2005: Novos Recursos T-SQL (SQL 2005)
TechEd 2005: Novos Recursos T-SQL (SQL 2005)
 
VorlonJS
VorlonJSVorlonJS
VorlonJS
 

Recently uploaded

Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 

Recently uploaded (20)

Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 

TechEd 2006: Trabalhando com DMV e DMF

  • 1. SUP303 - Trabalhando com DMV e DMF Fabricio Catae – Premier Field Engineer Ioannis Xylaras – Premier Field Engineer Microsoft Corporate
  • 2. 01. 02. 03. 04. 05. • Introdução • Arquitetura do SQL Server • Storage Engine • Relational Engine • Adicionais
  • 3. PREMIER FIELD ENGINEER • Suporte Global 24x7 • Atendimento a contratos Premier Support • Especialista de produto • Tipos de Serviços  Resolução de problemas  Análise proativa de ambientes críticos  Workshops e Transferência de conhecimento
  • 4. MOTIVAÇÃO • Objetivo  Utilizar DMV no dia a dia • Vantagens  Nova ferramenta disponível no SQL 2005  Revela detalhes sobre o funcionamento do servidor  Executa tarefas que não são possíveis no SQL 2000
  • 5. DYNAMIC MANAGEMENT OBJECTS • Dynamic Management Objects  Dynamic Management Views (DMV)  Dynamic Management Functions (DMF) • Características  Somente para leitura  Informação em memória  Capturas instantâneas (snapshot)
  • 6. CONSULTAS A DMV/DMF • Informações internas do SQL Server
  • 7. TRABALHANDO COM DMV E DMF • Dynamic Management Objects  Schema: sys  Nome: dm_* • Exemplos: SELECT * FROM sys.dm_exec_requests SELECT * FROM sys.dm_exec_sessions SELECT * FROM sys.dm_exec_connections SELECT * FROM sys.dm_exec_sql_text(@h)
  • 8. GRUPOS FUNCIONAIS • DMV/DMF estão organizados em categorias  Common Language Runtime (CLR)  Database Mirroring  Database  Execution  Indexes  I/O Operations  Query Notifications  Replication  Service Broker  SQL Server Operating System  Transaction
  • 9. DEMO • Select * from sys.system_objects Where name like ‘dm_%’ • Books Online 2005  “Dynamic Management Objects”  “sys.dm_exec_requests”
  • 10. ARQUITETURA DO SQL SERVER • Storage Engine  Infra-estrutura do SQL Server  Comunicação com o Sistema Operacional  Exemplos:  Gerenciamento de Threads  Gerenciamento de Memória  Gerenciamento de I/O • Relational Engine  Implementação da linguagem SQL  Conceito de índices e estatísticas  Exemplos:  Compilação  Otimização  Execução da query
  • 11. STORAGE ENGINE • Infra-estrutura do SQL Server  Thread  Memória  I/O
  • 13. TASK / TAREFAS • Running, Runnable, Suspended Task Task Task Task Task Task RUNNING RUNNABLE SUSPENDED
  • 14. 100% CPU • sys.dm_os_tasks  task_state  RUNNING  RUNNABLE Worker Task Worker Task Worker Task Worker Task
  • 16. SUSPENDED • Tarefas Bloqueadas  Disco  Rede  Linked Server • sys.dm_os_waiting_tasks  session_id  wait_type  wait_duration_ms  resource_description  blocking_session_id
  • 17. DISK I/O • Tarefas Bloqueadas  Data Files: PAGEIOLATCH  Log Files: WRITELOG • sys.dm_io_virtual_file_stats  database_id  file_id  num_of_reads  num_of_writes  num_of_bytes_read  num_of_bytes_written NG Auth Sidep AC MM
  • 19. GERENCIAMENTO DE MEMÓRIA • Módulo Reescrito para SQL 2005  Memory Nodes  Memory Clerks  Cache e User Stores  Page Allocators
  • 20. DM_OS_MEMORY_* • dm_os_memory_clerks • User e Cache Stores  dm_os_memory_cache_counters  dm_os_memory_cache_hash_tables  dm_os_memory_cache_clock  dm_os_memory_cache_entries • Object Stores  dm_os_memory_pools
  • 22. RELATIONAL ENGINE • Execução de Query • Histórico de Execução • Utilização de Índices
  • 23. EXECUÇÃO DE QUERY - session_id - sql_handle - plan_handle - estatísticas - cpu - memória - i/o - duração Session Connection Request Request Request
  • 24. REQUEST DMV • DMV  sys.dm_exec_connections  sys.dm_exec_sessions  sys.dm_exec_requests • DMF  sys.dm_exec_connections( sql_handle )  sys.dm_exec_connections( plan_handle )
  • 25. DEMO • Cenário: 100% CPU • Select * from sys.dm_exec_connections • Select * from sys.dm_exec_sessions • Select * from sys.dm_exec_requests • Select * from sys.dm_exec_sql_text(@h) • Use substring • Select * from sys.dm_exec_requests • CROSS APPLY operator • Select * from sys.dm_exec_plan_handle(@h) • Save query plan to with sqlplan file extension
  • 26. HISTÓRICO DE EXECUÇÃO • Após cada execução, essa DMV é atualizada • Colunas  sql_handle  plan_generation_num  plan_handle  last_execution  execution_count  total_worker_time  total_physical_read/write  total_logical_read/write  total_elapsed_time
  • 29. TEMPO DE CPU UTILIZADO (MS) • Total_worker_time
  • 30. TEMPO TOTAL GASTO (MS) • Total_elapsed_time
  • 31. DM_EXEC_QUERY_STATS • Algumas queries não aparecem  Extended Stored Procedures  .NET Stored Procedures  Comandos T-SQL (IF, WHILE, etc)  Queries triviais • Existem situações que removem parte das estatísticas  DBCC FREEPROCCACHE  Memory Pressure
  • 32. DEMO • Cenário: I/O intensive • Verificar que não há problemas • SELECT * FROM sys.dm_exec_requests • Listar todas as queries de sys.dm_exec_query_stats • Identificar os consumidores de CPU • Identificar os responsáveis pelos physical read • Calcular a média de leituras físicas • Utilizar sql_handle e plan_handle
  • 33. ÍNDICES • Falta de índices adequados para queries  sys.dm_db_missing_index_details • Utilização de Índices  sys.dm_db_index_usage_stats
  • 35. ADICIONAIS • Server level  dm_exec_*  Execution of user code and associated connections  dm_os_*  low level system (server-wide) info such as memory, locking & scheduling  dm_tran_*  Transactions & isolation  dm_io_*  Input/Output on network and disks  dm_db_*  Databases and database objects • GRUPO DE DMV’S
  • 36. ADICIONAIS • Component level  dm_repl_*  Replication  dm_broker_*  SQL Service Broker  dm_fts_*  Full Text Search  dm_qn_*  Query Notifications • GRUPO DE DMV’S
  • 37. ADICIONAIS • MEMÓRIA ALOCADA • Você pode usar o sys.dm_os_memory_clerks DMV como exemplo a seguir para identificar quanta memória o SQL Server aloca através do mecanismo do AWE. • Select sum(awe_allocated_kb) / 1024 as [AWE allocated, Mb] from sys.dm_os_memory_clerks • • CENÁRIO DE PERFORMANCE
  • 38. ADICIONAIS • Query plan ineficiente • A query sys.dm_exec_query_stats é um eficiente caminho para determinar qual query está usando a maior CPU cumulativa. • Select • highest_cpu_queries.plan_handle, • highest_cpu_queries.total_worker_time, • q.dbid, q.objectid, q.number, q.encrypted, q.[text] • from • (select top 50 qs.plan_handle, qs.total_worker_time • from sys.dm_exec_query_statssys.dm_exec_query_stats qs • order by qs.total_worker_time desc) as highest_cpu_queries • cross apply sys.dm_exec_sql_text(plan_handle) as q • order by highest_cpu_queries.total_worker_time desc • CENÁRIO DE PERFORMANCE
  • 39. ADICIONAIS • Top CPUs procs & batches Select top 50 • sum(qs.total_worker_time) as total_cpu_time, • sum(qs.execution_count) as total_execution_count, • count(*) as '#_statements', • qt.dbid, qt.objectid, qs.sql_handle, • qt.[text] from sys.dm_exec_query_stats as qs • cross apply sys.dm_exec_sql_text (qs.sql_handle) as qt • group by qt.dbid,qt.objectid, qs.sql_handle,qt.[text] • order by sum(qs.total_worker_time) desc,qs.sql_handle • CENÁRIO DE PERFORMANCE
  • 40. ADICIONAIS • CPU – O que está executando em paralelo? • Paralelismo é bom para DW, não para OLTP Select r.session_id, r.request_id, max(isnull(exec_context_id, 0)) as number_of_workers, r.sql_handle, r.statement_start_offset, r.statement_end_offset, r.plan_handle from sys.dm_exec_requestssys.dm_exec_requests r join sys.dm_os_tasks t on r.session_id = t.session_id join sys.dm_exec_sessions s on r.session_id = s.session_id where s.is_user_process = 0x1 group by r.session_id, r.request_id, r.sql_handle, r.plan_handle, r.statement_start_offset, r.statement_end_offset having max(isnull(exec_context_id, 0)) > 0 • CENÁRIO DE PERFORMANCE
  • 41. ADICIONAIS • Pressão CPU : Recompilação • Select top 25 • sql_text.text, • sql_handle, • plan_generation_num, • execution_count, • dbid, • objectid • from sys.dm_exec_query_statssys.dm_exec_query_stats a • Cross apply sys.dm_exec_sql_text(sql_handle) as sql_text • where plan_generation_num >1 • order by plan_generation_num desc • CENÁRIO DE PERFORMANCE
  • 42. ADICIONAIS • Memória: Top memory por objeto & índice • CENÁRIO DE PERFORMANCE Select b.database_id ,p.object_id ,object_name(p.object_id) as objname ,p.index_id ,buffer_count=count(*) from sys.allocation_units a, sys.dm_os_buffer_descriptorssys.dm_os_buffer_descriptors b, sys.partitions p where a.allocation_unit_id = b.allocation_unit_id and a.container_id = p.hobt_id group by b.database_id,p.object_id, p.index_id order by buffer_count desc
  • 43. ADICIONAIS • Top IOs por statement • SELECT TOP 50 • (qs.total_logical_reads + qs.total_logical_writes) /qs.execution_count • as [Avg IO], • substring (qt.text,qs.statement_start_offset/2, (case when qs.statement_end_offset = -1 • then len(convert(nvarchar(max), qt.text)) * 2 • else qs.statement_end_offset end -qs.statement_start_offset)/2) • as query_text, • qt.dbid, • qt.objectid • FROM sys.dm_exec_query_statssys.dm_exec_query_stats qs • cross apply sys.dm_exec_sql_text (qs.sql_handle) as qt • ORDER BY • [Avg IO] DESC • CENÁRIO DE PERFORMANCE
  • 44. ADICIONAIS • Visualizando a utilização dos índices das tabelas • Select so.name AS 'Table Name', si.name AS 'index Name', si.type_desc AS 'Index Type', si.index_id AS 'Index ID', us.user_seeks, us.user_scans, us.system_seeks, us.system_scans FROM sys.dm_db_index_usage_statssys.dm_db_index_usage_stats us INNER JOIN sys.objects so ON us.object_id = so.object_id INNER JOIN sys.indexes si ON so.object_id = si.object_id WHERE so.type = 'U' • CENÁRIO DE PERFORMANCE
  • 45. ADICIONAIS • Visualizando Índices não atualmente utilizados Select so.name AS 'Table Name', si.name AS 'index Name', si.type_desc AS 'Index Type', si.index_id AS 'Index ID', • us.user_seeks, us.user_scans, us.system_seeks, us.system_scans, us.user_lookups, us.system_lookups,us.user_updates, • us.system_updates • --other columns are available • FROM sys.dm_db_index_usage_statssys.dm_db_index_usage_stats us • INNER JOIN sys.objects so ON us.object_id = so.object_id • INNER JOIN sys.indexes si ON so.object_id = si.object_id • WHERE so.type = 'U' AND us.user_seeks = 0 • AND us.user_scans = 0 AND us.system_seeks = 0 • AND us.system_scans = 0 • CENÁRIO DE PERFORMANCE
  • 47. PRÓXIMAS PALESTRAS Palestra 1: Palestra 2: Palestra 3: • SUP304 Otimizando os Subsistemas de Discos para o Microsoft Exchange Server 30/11/2006 15:30 - 16:45 • SUP305 Processo de Migração para ISA Server 2006 30/11/2006 17:00 - 18:15 • Ask the Experts
  • 48. LINKS ÚTEIS SQL Server 2005 System Views Online http://download.microsoft.com/download/0/d/f/0df e488e-a335-4480-8a8a- b405e32f4368/SQL2005_Sys_Views.pdf Troubleshooting Performance Problems in SQL 2005 http://www.microsoft.com/technet/prodtechn ol/sql/2005/tsprfprb.mspx SQL Server 2005 Books Online http://www.microsoft.com/technet/prodtechn ol/sql/2005/downloads/books.mspx Dynamic Management Views and Functions http://msdn2.microsoft.com/en- us/library/ms188754.aspx
  • 49. LINKS ÚTEIS Technet Brasil http://www.microsoft.com/brasil/technet http://www.microsoft.com/brasil/technet/comunid ade/default.mspx http://forums.microsoft.com/technet-br Certificações Microsoft http://www.microsoft.com/brasil/certifique http://www.microsoft.com/learning Slava Oks Blog http://blogs.msdn.com/slavao Microsoft Most Valuable Professional http://mvp.support.microsoft.com/
  • 50. PERGUNTAS E RESPOSTAS • Fabricio Catae Ioannis Xylaras •• Microsoft Corporate