SQL Club Meeting – Lausanne, Switzerland04 September 2008
2nd SQL Server Club
4th of September 2008
Lausanne, Switzerland
04 September 2008 SQL Club Meeting – Lausanne, Switzerland
Some tools and interfaces that are available for
Performance Management and how they can be
leveraged to fit general enterprise needs.
Charley Hanania
B.Sc (Computing Science), MCP, MCDBA, MCITP, MCTS, MCT
UBS Investment Bank
Charley.Hanania@gmail.com
http://blogs.mssqltips.com/blogs/charleyhanania/
SQL Club Meeting – Lausanne, Switzerland04 September 2008
General Overview
 SQL Server has been “Enterprise Ready” for quite
some time now, and Microsoft are adding more and
more to the base architecture and tools to create
standard approaches and interfaces to the way that
DBAs and Support Professionals manage and report on
performance.
 We will discuss key business drivers for managing and
reporting on these and the tools and interfaces that can
be leveraged to meet some of these needs.
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Agenda
 Enterprise Performance Management
 Technologies and Methodologies
 Recap
 Discussion
04 September 2008 SQL Club Meeting – Lausanne, Switzerland
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Enterprise Performance Management
 What are your drivers to Performance Management?
 Consistent and predictable services.
 Root cause analysis.
 Performance Tuning.
 Platform capacity planning.
 Transparency of platform performance.
 What are the major components?
 Measurement.
 Reporting.
 Capacity planning.
 Governance.
The Triggers…
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Enterprise Performance Management
 Performance management metrics and indicators are
focussed on infrastructure components such as DBMS,
Storage, Network, Application etc.
 Assessing overall performance is the analysis of all the
metrics for associated infrastructure components
against performance indicators.
 SQL Server exposes a lot in terms of interfaces to
performance (some say too much!), the trick is whether the
presentation of it leads towards answering the questions
you‟re asking.
SQL Server vs Overall Operations…
SQL Club Meeting – Lausanne, Switzerland04 September 2008
The 7-Step Improvement Process
1. Define what you should measure
2. Define what you can measure
3. Gathering the data
4. Processing the data
5. Analysing the data
6. Presenting and using the information
7. Implementing corrective action
An ITIL Methodology (v3)…
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Forrester Case Study
 Focus / Aims:
 Break news fast (2 minutes faster than competitors!).
 A rich user experience.
 “Blazing fast Web site performance”
 How?
 Measure performance early and often.
 Watch for signs of stress in the site infrastructure.
○ … And proactively respond 
 Leverage cross-discipline performance teams.
 Constantly optimise the infrastructure
Msnbc.com is first in News…
SQL Club Meeting – Lausanne, Switzerland04 September 2008
OK
Back to SQL Server
04 September 2008 SQL Club Meeting – Lausanne, Switzerland
What core technologies are there and how can we use them?
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Technologies and Methodologies
 Performance Dashboard Reports
 DMVStats
 SQL Server 2008 Management Studio
 Management Data Warehouse
 MOM / SCOM
 SQL Server Health and History Tool
 Performance Point
Overview of Tools we‟ll touch on
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Dashboard Reports
 Used mainly for immediate insight into root causes of
performance issues.
 Leverages SQL Server DMVs.
 Common performance problems it may help to resolve:
 CPU bottlenecks (and what queries are consuming the most CPU)
 IO bottlenecks (and what queries are performing the most IO).
 Index recommendations (generated by the query optimizer)
 Blocking
 Latch contention
 Integrated into SQL Server Management Studio
 Works for 2005 & 2008
http://blogs.msdn.com/psssql/archive/2007/03/30/sql-server-2005-performance-dashboard-reports.aspx
http://www.microsoft.com/downloads/details.aspx?familyid=1d3a4a0d-7e0c-4730-8204-e419218c1efc&displaylang=en
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Dashboard Reports
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Dashboard Reports
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Dashboard Reports
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Dashboard Reports
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Technologies and Methodologies
 Performance Dashboard Reports
 DMVStats
 SQL Server 2008 Management Studio
 Management Data Warehouse
 MOM / SCOM
 SQL Server Health and History Tool
 Performance Point
Overview of Tools we‟ll touch on
SQL Club Meeting – Lausanne, Switzerland04 September 2008
DMVStats
 Collects performance oriented DMV data into a data
warehouse, and provides a methodology called 'Waits' and
'Queues' to identify and track down performance issues.
 Focussed on common user scenarios that are still difficult to
analyze and pinpoint:
 What happened yesterday or last week? (e.g. historical forensics)
 Trending
 Source of obscure or transient waits (*not included in query stats)
 Comparisons before and after application changes
 Analysis is provided by reporting services reports
 Works for 2005 & 2008
http://www.codeplex.com/sqldmvstats
SQL Club Meeting – Lausanne, Switzerland04 September 2008
DMV Stats
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Technologies and Methodologies
 Performance Dashboard Reports
 DMVStats
 SQL Server 2008 Management Studio
 Management Data Warehouse
 MOM / SCOM
 SQL Server Health and History Tool
 Performance Point
Overview of Tools we‟ll touch on
SQL Club Meeting – Lausanne, Switzerland04 September 2008
SQL Server 2008 Management Studio
 Real time view of resource usage
 Integrated into SQL Server Management Studio
 Works for SQL Server 2005 and 2008 instances.
Activity Monitor
SQL Club Meeting – Lausanne, Switzerland04 September 2008
SQL Server 2008 Management Studio
SQL Server 2008
SQL Server 2005
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Monitoring Tools
Roadmap
Historical and
baseline
comparisons
Trouble-shooting
and Tuning
Performance and
Diagnostics
Monitoring
Data Collection
Data
Collection
Sets
System
Collection Sets
Reports
Management
Data
Warehouse
Policy based
management
Based on SQL Server 2008 Management Studio
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Technologies and Methodologies
 Performance Dashboard Reports
 DMVStats
 SQL Server 2008 Management Studio
 Management Data Warehouse
 MOM / SCOM
 SQL Server Health and History Tool
 Performance Point
Overview of Tools we‟ll touch on
SQL Club Meeting – Lausanne, Switzerland04 September 2008
The Management Data Warehouse
 Takes snapshots of server and DBMS instance data for
historical analysis.
 Uses a data collector process to populate the DW.
 Reports are provided for System Data Collection sets that are
installed during setup:
 Disk Usage
 Query Statistics
 Server Activity
 Extendable: New collector types can be created
 Integrated into SQL Server Management Studio
 Works SQL Server 2008
ms-help://MS.SQLCC.v10/MS.SQLSVR.v10.en/s10de_4deptrbl/html/9874a8b2-7ccd-494a-944c-ad33b30b5499.htm
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Data Warehouse
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Data Warehouse
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Data Warehouse
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Technologies and Methodologies
 Performance Dashboard Reports
 DMVStats
 SQL Server 2008 Management Studio
 Management Data Warehouse
 MOM / SCOM
 SQL Server Health and History Tool
 Performance Point
Overview of Tools we‟ll touch on
SQL Club Meeting – Lausanne, Switzerland04 September 2008
MOM / SCOM (Operations Manager)
 Operations Manager is now part of System Centre 2007.
 Uses an agent to pick up alerts, events and counters through
management packs.
 Sends these through to a data warehouse.
 Can be further plugged into BI infra with AS/RS, Performance Point etc.
 Can report on any and all available counters and interfaces
 Service Level Dashboard for SCOM 2007 available on
Microsoft Connect.
 Careful:
 Plan what you want to collect. The DW can get very large.
 Keep what you can afford to for future investigations and comparisons.
ms-help://MS.SQLCC.v10/MS.SQLSVR.v10.en/s10de_4deptrbl/html/9874a8b2-7ccd-494a-944c-ad33b30b5499.htm
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Microsoft / System Centre
Operations Manager
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Microsoft / System Centre
Operations Manager
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Technologies and Methodologies
 Performance Dashboard Reports
 DMVStats
 SQL Server 2008 Management Studio
 Management Data Warehouse
 MOM / SCOM
 SQL Server Health and History Tool
 Performance Point
Overview of Tools we‟ll touch on
SQL Club Meeting – Lausanne, Switzerland04 September 2008
SQL Server Health and History Tool
 Stores information from SQL Server instances in a repository to run reports
which determine how SQL Server is being used.
 Collects four main types of information:
 Feature Usage
○ What services/features are installed, running and level of workload on the service.
 Configuration Settings
○ Machine, OS and SQL configuration settings, SQL instance and database metadata.
 Uptime of the SQL Server service
 Performance Counters (optional)
○ Used to determine performance trends
 Performance Collector (stand alone service) used to collect performance counters
 Predefined reports viewed through Reporting Services.
 Works on SQL Server 2000 and 2005. Issues around 2008 due to RS changes.
http://www.microsoft.com/downloads/details.aspx?familyid=EEDD10D6-75F7-4763-86DE-D2347B8B5F89&displaylang=en
SQL Club Meeting – Lausanne, Switzerland04 September 2008
SQL Server Health and History Tool
The SQLH2 utility records snapshots of one or more servers into a repository database. It does not
provide real time monitoring, but it does provide a history of changes made to your servers. From hotfixes
applied to the operating system to database growth to SQL Server settings, there is a wealth of
information recorded. Even more data is collected from SQL 2005, things like triggers, assemblies and
backups. Thirteen ready-made SQL Reporting Services reports are available to view the information.
You do not install anything on the target servers. The data is pulled to the collector.
Quoting Kathi Kellenberger from a SQLServer Central Article:
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Technologies and Methodologies
 Performance Dashboard Reports
 DMVStats
 SQL Server 2008 Management Studio
 Management Data Warehouse
 MOM / SCOM
 SQL Server Health and History Tool
 Performance Point
Overview of Tools we‟ll touch on
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Point Scorecards and
Dashboards
 Not a Performance Tool
 Framework for presenting your data with:
 Scorecards
 KPI‟s
 Integrated dashboards
 Drill through
 Etc…
SQL Club Meeting – Lausanne, Switzerland04 September 2008
 Integrated (balanced) view of IT Performance
 Roll up disparate metrics in a single scorecard – Server capacity,
Transactions, SLA measurement
 Ad-hoc analytics
 Help determine root cause for usage spikes, application
downtime
 Predictive analytics
 What will my capacity needs look like next year?
 Planning
 Capacity Planning
 Resource Planning / Headcount
 IT Budgeting / Forecasting
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Point
Availability Metrics
Performance Counters
Monitor State Detail
Hourly Data
Daily Trends
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Root-cause Analysis and Trending
04 September 2008 SQL Club Meeting – Lausanne, Switzerland
Resource Governor and Extended Events
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Resource Governor
 Resource governor provides the ability to:
 Classify incoming connections and assign to a pre-defined
workload group
 Group resources into resource pools and set pool-specific limits
on CPU usage and memory allocation
 Map workload groups to resource pools
 Monitor resource usage by workload group
 Prioritize workload groups relative to each other
 Dynamically alter any of the above
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Resource Governor: Example
Scenarios
 Run-away queries
 Prior to SS2008, DBAs could control access to tables and
indexes but NOT to system resource usage
 Prevent or minimize possibility by „sand-boxing‟
 Unpredictable workload execution
 Prior to SS2008, no way to guarantee performance service-level
agreements for co-hosted workloads
 Provide mission critical workloads resources they need while
also preventing workloads from abusing resources
 Setting workload priority
 Allows workloads to be assigned relative priorities (but with no
*guarantees*)
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Resource Governor: Limitations
 Work with the Database Engine only
 Single instance only
 Each instance controlled individually
 Can be combined with Windows System Resource Manager
(WSRM) on Windows Server 2003 for CPU and memory control
 Controls for CPU usage and memory allocation ONLY
 I/O controls are planned for V2
 Certain workloads may not be entirely suited – e.g. short-lived
OLTP queries
 No chargeback mechanism
 But you can roll your own more easily using the monitoring
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Extended Events: What is it?
 Advanced eventing infrastructure for servers
 Ability to define events to monitor and a variety of ways
to consume the events
 Synchronous or asynchronous
 Trigger actions when an event fires
 Use predicates to filter events from consumers
 Causality tracking (through inherited IDs)
 High performance and good scalability
 Cost of firing a single event is extremely small
 ETW (Event Tracing for Windows) enabled
 Controlled through T-SQL DDL statements
Feb-2008 46
Microsoft
Developer &
Platform
Evangelism
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Extended Events: Why?
 Example scenario (taken from Books Online):
 Problem
 Troubleshooting excessive CPU usage on the server
 DMVs show that all queries are ad-hoc user queries but don‟t
have enough info about queries that have been run
 Solution
 Create an Extended Events session that:
○ Fires an event when a T-SQL statement executes
○ Defines an event action to collect the query plan
○ Defines a predicate on a CPU usage threshold
○ Defines a consumer to write the event payload to a trace file
 Examination of the traced query plans allows pinpointing the
problem
Feb-2008 47
Microsoft
Developer &
Platform
Evangelism
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Performance Tools Compared
Content
Type
Installation
Reporting
Method
SQL Server
Versions
Supported
Performance Dashboard Reports Current Simple SSMS/RS 1 2005/2008
DMVStats Historical Medium RS 2005/2008
SQL Server 2008 Management Studio Current In-built SSMS 2005/2008
Management Data Warehouse Historical Simple SSMS 2008
MOM / SCOM Historical Medium / Difficult RS 2000 / 2005 / 2008
SQL Server Health and History Tool Historical Medium RS 2000 / 2005 / 2008 2
Performance Point N/A Medium / Difficult Sharepoint N/A
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Other Tools – Not Covered
 RML Utilities for SQL Server
 Ability to process SQL Server trace files and view reports showing
how SQL Server is performing. (eg which application, database,
login and query is using the most resources etc)
 Also able to replay traces on other configurations. eg. After Service
Pack or hotfix, changing of indexes etc, comparing results directly
against the baseline captured trace.
 SQLIO Disk Subsystem Benchmark Tool
 Can be used to determine the I/O capacity of a given system
configuration.
 SQL Server 2005 Best Practices Analyzer
 Gathers data from Windows and SQL Server configuration settings.
 Uses a predefined list of SQL Server recommendations and best
practices to determine if there are potential issues in the database
environment.
Due to time, not importance…
04 September 2008 SQL Club Meeting – Lausanne, Switzerland
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Recap
 Managing Performance must be holistic to be useful.
 Ask the right questions to focus your measurements and
methodologies. Too much of the wrong data is useless!
 A baseline and continued performance gathering framework
acts as the basis of moving from a Reactive to a Strategic /
Best of Breed IT organisation.
 There are a wealth of tools available, but most require
additional effort before it is truly useful.
 Applying BI to our collected operational databases positions
the organisation to better understand how investments in
hardware, people, systems, divisions and strategies pay off.
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Topic Resources
 TechEd US 2008
 BIN351: Operations Management Scorecards and Dashboards
 Forrester Research, Inc
○ http://www.forrester.com
 Resource Governor
 Books Online – search for „Resource Governor‟
 Technical Webcast
○ http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?EventID=1032365547
 Extended Events
 Books Online – search for „Extended Events‟
 Technical Webcast
○ http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?EventID=1032356291
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Community
 Swiss PASS Chapter
 www.sqlpass-swiss.org
 Swiss IT Pro user group
 www.swissitpro.ch
 Monthly sessions in Zurich and Geneva
SQL Club Meeting – Lausanne, Switzerland04 September 2008
Thank
you…

Sql server club - performance management methodologies and enhancements in sql server - charley hanania

  • 1.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 2nd SQL Server Club 4th of September 2008 Lausanne, Switzerland
  • 2.
    04 September 2008SQL Club Meeting – Lausanne, Switzerland Some tools and interfaces that are available for Performance Management and how they can be leveraged to fit general enterprise needs. Charley Hanania B.Sc (Computing Science), MCP, MCDBA, MCITP, MCTS, MCT UBS Investment Bank Charley.Hanania@gmail.com http://blogs.mssqltips.com/blogs/charleyhanania/
  • 3.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 General Overview  SQL Server has been “Enterprise Ready” for quite some time now, and Microsoft are adding more and more to the base architecture and tools to create standard approaches and interfaces to the way that DBAs and Support Professionals manage and report on performance.  We will discuss key business drivers for managing and reporting on these and the tools and interfaces that can be leveraged to meet some of these needs.
  • 4.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Agenda  Enterprise Performance Management  Technologies and Methodologies  Recap  Discussion
  • 5.
    04 September 2008SQL Club Meeting – Lausanne, Switzerland
  • 6.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Enterprise Performance Management  What are your drivers to Performance Management?  Consistent and predictable services.  Root cause analysis.  Performance Tuning.  Platform capacity planning.  Transparency of platform performance.  What are the major components?  Measurement.  Reporting.  Capacity planning.  Governance. The Triggers…
  • 7.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Enterprise Performance Management  Performance management metrics and indicators are focussed on infrastructure components such as DBMS, Storage, Network, Application etc.  Assessing overall performance is the analysis of all the metrics for associated infrastructure components against performance indicators.  SQL Server exposes a lot in terms of interfaces to performance (some say too much!), the trick is whether the presentation of it leads towards answering the questions you‟re asking. SQL Server vs Overall Operations…
  • 8.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 The 7-Step Improvement Process 1. Define what you should measure 2. Define what you can measure 3. Gathering the data 4. Processing the data 5. Analysing the data 6. Presenting and using the information 7. Implementing corrective action An ITIL Methodology (v3)…
  • 9.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Forrester Case Study  Focus / Aims:  Break news fast (2 minutes faster than competitors!).  A rich user experience.  “Blazing fast Web site performance”  How?  Measure performance early and often.  Watch for signs of stress in the site infrastructure. ○ … And proactively respond   Leverage cross-discipline performance teams.  Constantly optimise the infrastructure Msnbc.com is first in News…
  • 10.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 OK Back to SQL Server
  • 11.
    04 September 2008SQL Club Meeting – Lausanne, Switzerland What core technologies are there and how can we use them?
  • 12.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Technologies and Methodologies  Performance Dashboard Reports  DMVStats  SQL Server 2008 Management Studio  Management Data Warehouse  MOM / SCOM  SQL Server Health and History Tool  Performance Point Overview of Tools we‟ll touch on
  • 13.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Dashboard Reports  Used mainly for immediate insight into root causes of performance issues.  Leverages SQL Server DMVs.  Common performance problems it may help to resolve:  CPU bottlenecks (and what queries are consuming the most CPU)  IO bottlenecks (and what queries are performing the most IO).  Index recommendations (generated by the query optimizer)  Blocking  Latch contention  Integrated into SQL Server Management Studio  Works for 2005 & 2008 http://blogs.msdn.com/psssql/archive/2007/03/30/sql-server-2005-performance-dashboard-reports.aspx http://www.microsoft.com/downloads/details.aspx?familyid=1d3a4a0d-7e0c-4730-8204-e419218c1efc&displaylang=en
  • 14.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Dashboard Reports
  • 15.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Dashboard Reports
  • 16.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Dashboard Reports
  • 17.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Dashboard Reports
  • 18.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Technologies and Methodologies  Performance Dashboard Reports  DMVStats  SQL Server 2008 Management Studio  Management Data Warehouse  MOM / SCOM  SQL Server Health and History Tool  Performance Point Overview of Tools we‟ll touch on
  • 19.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 DMVStats  Collects performance oriented DMV data into a data warehouse, and provides a methodology called 'Waits' and 'Queues' to identify and track down performance issues.  Focussed on common user scenarios that are still difficult to analyze and pinpoint:  What happened yesterday or last week? (e.g. historical forensics)  Trending  Source of obscure or transient waits (*not included in query stats)  Comparisons before and after application changes  Analysis is provided by reporting services reports  Works for 2005 & 2008 http://www.codeplex.com/sqldmvstats
  • 20.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 DMV Stats
  • 21.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Technologies and Methodologies  Performance Dashboard Reports  DMVStats  SQL Server 2008 Management Studio  Management Data Warehouse  MOM / SCOM  SQL Server Health and History Tool  Performance Point Overview of Tools we‟ll touch on
  • 22.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 SQL Server 2008 Management Studio  Real time view of resource usage  Integrated into SQL Server Management Studio  Works for SQL Server 2005 and 2008 instances. Activity Monitor
  • 23.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 SQL Server 2008 Management Studio SQL Server 2008 SQL Server 2005
  • 24.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Monitoring Tools Roadmap Historical and baseline comparisons Trouble-shooting and Tuning Performance and Diagnostics Monitoring Data Collection Data Collection Sets System Collection Sets Reports Management Data Warehouse Policy based management Based on SQL Server 2008 Management Studio
  • 25.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Technologies and Methodologies  Performance Dashboard Reports  DMVStats  SQL Server 2008 Management Studio  Management Data Warehouse  MOM / SCOM  SQL Server Health and History Tool  Performance Point Overview of Tools we‟ll touch on
  • 26.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 The Management Data Warehouse  Takes snapshots of server and DBMS instance data for historical analysis.  Uses a data collector process to populate the DW.  Reports are provided for System Data Collection sets that are installed during setup:  Disk Usage  Query Statistics  Server Activity  Extendable: New collector types can be created  Integrated into SQL Server Management Studio  Works SQL Server 2008 ms-help://MS.SQLCC.v10/MS.SQLSVR.v10.en/s10de_4deptrbl/html/9874a8b2-7ccd-494a-944c-ad33b30b5499.htm
  • 27.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Data Warehouse
  • 28.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Data Warehouse
  • 29.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Data Warehouse
  • 30.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Technologies and Methodologies  Performance Dashboard Reports  DMVStats  SQL Server 2008 Management Studio  Management Data Warehouse  MOM / SCOM  SQL Server Health and History Tool  Performance Point Overview of Tools we‟ll touch on
  • 31.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 MOM / SCOM (Operations Manager)  Operations Manager is now part of System Centre 2007.  Uses an agent to pick up alerts, events and counters through management packs.  Sends these through to a data warehouse.  Can be further plugged into BI infra with AS/RS, Performance Point etc.  Can report on any and all available counters and interfaces  Service Level Dashboard for SCOM 2007 available on Microsoft Connect.  Careful:  Plan what you want to collect. The DW can get very large.  Keep what you can afford to for future investigations and comparisons. ms-help://MS.SQLCC.v10/MS.SQLSVR.v10.en/s10de_4deptrbl/html/9874a8b2-7ccd-494a-944c-ad33b30b5499.htm
  • 32.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Microsoft / System Centre Operations Manager
  • 33.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Microsoft / System Centre Operations Manager
  • 34.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Technologies and Methodologies  Performance Dashboard Reports  DMVStats  SQL Server 2008 Management Studio  Management Data Warehouse  MOM / SCOM  SQL Server Health and History Tool  Performance Point Overview of Tools we‟ll touch on
  • 35.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 SQL Server Health and History Tool  Stores information from SQL Server instances in a repository to run reports which determine how SQL Server is being used.  Collects four main types of information:  Feature Usage ○ What services/features are installed, running and level of workload on the service.  Configuration Settings ○ Machine, OS and SQL configuration settings, SQL instance and database metadata.  Uptime of the SQL Server service  Performance Counters (optional) ○ Used to determine performance trends  Performance Collector (stand alone service) used to collect performance counters  Predefined reports viewed through Reporting Services.  Works on SQL Server 2000 and 2005. Issues around 2008 due to RS changes. http://www.microsoft.com/downloads/details.aspx?familyid=EEDD10D6-75F7-4763-86DE-D2347B8B5F89&displaylang=en
  • 36.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 SQL Server Health and History Tool The SQLH2 utility records snapshots of one or more servers into a repository database. It does not provide real time monitoring, but it does provide a history of changes made to your servers. From hotfixes applied to the operating system to database growth to SQL Server settings, there is a wealth of information recorded. Even more data is collected from SQL 2005, things like triggers, assemblies and backups. Thirteen ready-made SQL Reporting Services reports are available to view the information. You do not install anything on the target servers. The data is pulled to the collector. Quoting Kathi Kellenberger from a SQLServer Central Article:
  • 37.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Technologies and Methodologies  Performance Dashboard Reports  DMVStats  SQL Server 2008 Management Studio  Management Data Warehouse  MOM / SCOM  SQL Server Health and History Tool  Performance Point Overview of Tools we‟ll touch on
  • 38.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Point Scorecards and Dashboards  Not a Performance Tool  Framework for presenting your data with:  Scorecards  KPI‟s  Integrated dashboards  Drill through  Etc…
  • 39.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008  Integrated (balanced) view of IT Performance  Roll up disparate metrics in a single scorecard – Server capacity, Transactions, SLA measurement  Ad-hoc analytics  Help determine root cause for usage spikes, application downtime  Predictive analytics  What will my capacity needs look like next year?  Planning  Capacity Planning  Resource Planning / Headcount  IT Budgeting / Forecasting
  • 40.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Point Availability Metrics Performance Counters Monitor State Detail Hourly Data Daily Trends
  • 41.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Root-cause Analysis and Trending
  • 42.
    04 September 2008SQL Club Meeting – Lausanne, Switzerland Resource Governor and Extended Events
  • 43.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Resource Governor  Resource governor provides the ability to:  Classify incoming connections and assign to a pre-defined workload group  Group resources into resource pools and set pool-specific limits on CPU usage and memory allocation  Map workload groups to resource pools  Monitor resource usage by workload group  Prioritize workload groups relative to each other  Dynamically alter any of the above
  • 44.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Resource Governor: Example Scenarios  Run-away queries  Prior to SS2008, DBAs could control access to tables and indexes but NOT to system resource usage  Prevent or minimize possibility by „sand-boxing‟  Unpredictable workload execution  Prior to SS2008, no way to guarantee performance service-level agreements for co-hosted workloads  Provide mission critical workloads resources they need while also preventing workloads from abusing resources  Setting workload priority  Allows workloads to be assigned relative priorities (but with no *guarantees*)
  • 45.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Resource Governor: Limitations  Work with the Database Engine only  Single instance only  Each instance controlled individually  Can be combined with Windows System Resource Manager (WSRM) on Windows Server 2003 for CPU and memory control  Controls for CPU usage and memory allocation ONLY  I/O controls are planned for V2  Certain workloads may not be entirely suited – e.g. short-lived OLTP queries  No chargeback mechanism  But you can roll your own more easily using the monitoring
  • 46.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Extended Events: What is it?  Advanced eventing infrastructure for servers  Ability to define events to monitor and a variety of ways to consume the events  Synchronous or asynchronous  Trigger actions when an event fires  Use predicates to filter events from consumers  Causality tracking (through inherited IDs)  High performance and good scalability  Cost of firing a single event is extremely small  ETW (Event Tracing for Windows) enabled  Controlled through T-SQL DDL statements Feb-2008 46 Microsoft Developer & Platform Evangelism
  • 47.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Extended Events: Why?  Example scenario (taken from Books Online):  Problem  Troubleshooting excessive CPU usage on the server  DMVs show that all queries are ad-hoc user queries but don‟t have enough info about queries that have been run  Solution  Create an Extended Events session that: ○ Fires an event when a T-SQL statement executes ○ Defines an event action to collect the query plan ○ Defines a predicate on a CPU usage threshold ○ Defines a consumer to write the event payload to a trace file  Examination of the traced query plans allows pinpointing the problem Feb-2008 47 Microsoft Developer & Platform Evangelism
  • 48.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Performance Tools Compared Content Type Installation Reporting Method SQL Server Versions Supported Performance Dashboard Reports Current Simple SSMS/RS 1 2005/2008 DMVStats Historical Medium RS 2005/2008 SQL Server 2008 Management Studio Current In-built SSMS 2005/2008 Management Data Warehouse Historical Simple SSMS 2008 MOM / SCOM Historical Medium / Difficult RS 2000 / 2005 / 2008 SQL Server Health and History Tool Historical Medium RS 2000 / 2005 / 2008 2 Performance Point N/A Medium / Difficult Sharepoint N/A
  • 49.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Other Tools – Not Covered  RML Utilities for SQL Server  Ability to process SQL Server trace files and view reports showing how SQL Server is performing. (eg which application, database, login and query is using the most resources etc)  Also able to replay traces on other configurations. eg. After Service Pack or hotfix, changing of indexes etc, comparing results directly against the baseline captured trace.  SQLIO Disk Subsystem Benchmark Tool  Can be used to determine the I/O capacity of a given system configuration.  SQL Server 2005 Best Practices Analyzer  Gathers data from Windows and SQL Server configuration settings.  Uses a predefined list of SQL Server recommendations and best practices to determine if there are potential issues in the database environment. Due to time, not importance…
  • 50.
    04 September 2008SQL Club Meeting – Lausanne, Switzerland
  • 51.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Recap  Managing Performance must be holistic to be useful.  Ask the right questions to focus your measurements and methodologies. Too much of the wrong data is useless!  A baseline and continued performance gathering framework acts as the basis of moving from a Reactive to a Strategic / Best of Breed IT organisation.  There are a wealth of tools available, but most require additional effort before it is truly useful.  Applying BI to our collected operational databases positions the organisation to better understand how investments in hardware, people, systems, divisions and strategies pay off.
  • 52.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Topic Resources  TechEd US 2008  BIN351: Operations Management Scorecards and Dashboards  Forrester Research, Inc ○ http://www.forrester.com  Resource Governor  Books Online – search for „Resource Governor‟  Technical Webcast ○ http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?EventID=1032365547  Extended Events  Books Online – search for „Extended Events‟  Technical Webcast ○ http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?EventID=1032356291
  • 53.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Community  Swiss PASS Chapter  www.sqlpass-swiss.org  Swiss IT Pro user group  www.swissitpro.ch  Monthly sessions in Zurich and Geneva
  • 54.
    SQL Club Meeting– Lausanne, Switzerland04 September 2008 Thank you…

Editor's Notes

  • #5 Performance Management vs. Performance ReportingDrivers: ITIL Stuff….Remember to touch on Resource Governor…Next step in the SQL Server Performance World will be using Analysis Services to …
  • #8 Some of the questions:1. Top x resource hogs (well which resources)? why are they hogging?  are they the problem or the underlying component?2. Is my DBMS reaching capacity? in terms of what?  Database space, connections, disk space, performance, recoverability etc…