0% found this document useful (0 votes)
40 views11 pages

2784A - W01 Measuring Database Performance

This document provides guidance on measuring database performance. It discusses establishing a performance baseline, using tools like SQL Server Profiler and Performance Monitor to monitor key metrics like query execution time and resource usage. Specific counters and events that each tool collects are outlined. Guidelines for identifying locking and blocking issues include monitoring procedures that cause long execution times or blocking. The lab scenario involves reviewing database schemas and scripts, capturing baseline performance, and prioritizing potential problems.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
40 views11 pages

2784A - W01 Measuring Database Performance

This document provides guidance on measuring database performance. It discusses establishing a performance baseline, using tools like SQL Server Profiler and Performance Monitor to monitor key metrics like query execution time and resource usage. Specific counters and events that each tool collects are outlined. Guidelines for identifying locking and blocking issues include monitoring procedures that cause long execution times or blocking. The lab scenario involves reviewing database schemas and scripts, capturing baseline performance, and prioritizing potential problems.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 11

Unit 1:

Measuring Database
Performance

Overview
Best Practices for Measuring Performance
Key Measures for Query Performance
Using Performance Monitor

Using SQL Server Profiler


Guidelines for Identifying Locking and Blocking

Lab Scenario
Lab Outcomes

Lab: Measuring Database Performance


Lab Discussion

Best Practices for Measuring Performance

When measuring performance:


Identify a performance baseline

Use appropriate SQL Server and Windows tools


SQL Server Profiler
Performance Monitor
Activity Monitor
Carefully select the performance problems to monitor
with each tool

Key Measures for Query Performance

Key factors for query performance:


Resources used to execute the query

Time required for query execution

SQL Server tools to measure query performance:


Performance Monitor
SQL Server Profiler

Using Performance Monitor

Useful Performance Monitor counters are:


SQLServer:Access Methods
SQLServer:SQL Statistics

SQLServer:Databases
SQLServer:Transactions
SQLServer:Locks

Using SQL Server Profiler


Useful SQL Server Profiler events are:
Stored Procedures category:
RPC:Completed
SP:Completed
SP:StmtCompleted
TSQL category:

SQL:StmtCompleted
SQL:BatchCompleted
Locks category:
Lock:Acquired
Lock:Released

Lock:Timeout

Guidelines for Identifying Locking and Blocking

Guidelines to identify procedures that cause locking


and blocking:
Use Activity Monitor
Use SQL Server Profiler blocked process report

Watch for situations in which the same procedure


executes in different amounts of time
Identify the transaction isolation level of the procedure

Lab Scenario
Background information
Current situation
Requirements

Lab Outcomes
Anomalies and issues with the physical
schema identified
Baseline performance times recorded
Potential concurrency issues identified
Prioritized list of potential problems or
issues recorded

Lab: Measuring Database Performance


Exercise 1: Reviewing Tables and
Scripts
Exercise 2: Capturing Baseline
Performance

Exercise 3: Prioritizing Identified


Problems

Lab Discussion
Does your company take regular baseline
measurements?
If not, why not? Why do most companies
not take baselines?

Could you automate the performance


baseline process?
From the analysis of the database, what
areas require review?

You might also like