Module 18 Monitoring SQL Server 2008 R2. Module Overview Monitoring Activity Capturing and Managing Performance Data Analyzing Collected Performance Data.

Slides:



Advertisements
Similar presentations
Course 2786B Module 8: Implementing an Active Directory® Domain Services Monitoring Plan Presentation: 60 minutes Lab: 60 minutes This module helps students.
Advertisements

DynaTrace Platform.
Module 13: Performance Tuning. Overview Performance tuning methodologies Instance level Database level Application level Overview of tools and techniques.
Module 12: Auditing SQL Server Environments
Module 17 Tracing Access to SQL Server 2008 R2. Module Overview Capturing Activity using SQL Server Profiler Improving Performance with the Database Engine.
Module 20 Troubleshooting Common SQL Server 2008 R2 Administrative Issues.
Module 3 Installing and Configuring SQL Server 2008 R2.
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment Chapter 11: Monitoring Server Performance.
Maintaining and Updating Windows Server 2008
MCTS Guide to Microsoft Windows Server 2008 Network Infrastructure Configuration Chapter 11 Managing and Monitoring a Windows Server 2008 Network.
Module 14 Monitoring and Maintaining Windows Server® 2008 Servers.
Module 8: Monitoring SQL Server for Performance. Overview Why to Monitor SQL Server Performance Monitoring and Tuning Tools for Monitoring SQL Server.
Connect with life Praveen Srvatsa Director | AsthraSoft Consulting Microsoft Regional Director, Bangalore Microsoft MVP, ASP.NET.
Chris Testa-O’Neill EMC Consulting. Agenda Resource Governor Integrating Performance Monitor and Profiler Policy Based Management Performance Data Collector.
Module 13 Automating SQL Server 2008 R2 Management.
Module 17 Storing XML Data in SQL Server® 2008 R2.
Course 6421A Module 7: Installing, Configuring, and Troubleshooting the Network Policy Server Role Service Presentation: 60 minutes Lab: 60 minutes Module.
Copyright © 2007 Quest Software The Changing Role of SQL Server DBA’s Bryan Oliver SQL Server Domain Expert Quest Software.
Module 15: Monitoring. Overview Formulate requirements and identify resources to monitor in a database environment Types of monitoring that can be carried.
Microsoft ® Official Course Module 12 Monitoring, Managing, and Recovering AD DS.
Course Topics Administering SQL Server 2012 Jump Start 01 | Install and Configure SQL Server04 | Manage Data 02 | Maintain Instances and Databases05 |
Module 12 Installing and Upgrading to SharePoint 2010.
Implementing File and Print Services
Module 8 Configuring and Securing SharePoint Services and Service Applications.
Microsoft ® Official Course Module 10 Optimizing and Maintaining Windows ® 8 Client Computers.
Conditions and Terms of Use
Module 7: Fundamentals of Administering Windows Server 2008.
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment, Enhanced Chapter 11: Monitoring Server Performance.
Module 19 Managing Multiple Servers. Module Overview Working with Multiple Servers Virtualizing SQL Server Deploying and Upgrading Data-Tier Applications.
Introducing the SQL Server 2008 Performance Data Collector by Brad McGehee August 20, 2008 Audio via phone conference (866) , the dial in code.
Module 7 Reading SQL Server® 2008 R2 Execution Plans.
Informix IDS Administration with the New Server Studio 4.0 By Lester Knutsen My experience with the beta of Server Studio and the new Informix database.
Module 10: Monitoring ISA Server Overview Monitoring Overview Configuring Alerts Configuring Session Monitoring Configuring Logging Configuring.
Module 11: Remote Access Fundamentals
Module 6 Backup of SQL Server 2008 R2 Databases. Module Overview Backing up Databases and Transaction Logs Managing Database Backups Working with Backup.
Performance Dash A free tool from Microsoft that provides some quick real time information about the status of your SQL Servers.
Learningcomputer.com SQL Server 2008 – Administration, Maintenance and Job Automation.
Module 14 Configuring Security for SQL Server Agent.
Monitoring Windows Server 2012
Learningcomputer.com SQL Server 2008 – Profiling and Monitoring Tools.
Module 16: Performing Ongoing Database Maintenance
Module 10 Assigning Server and Database Roles. Module Overview Working with Server Roles Working with Fixed Database Roles Creating User-defined Database.
1 Chapter Overview Performing Configuration Tasks Setting Up Additional Features Performing Maintenance Tasks.
Module 15 Monitoring SQL Server 2008 R2 with Alerts and Notifications.
Module 14 Monitoring and Optimizing SharePoint Performance.
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment, Enhanced Chapter 11: Monitoring Server Performance.
Module 8: Implementing an Active Directory Domain ® Services Monitoring Plan.
Module 3 Designing and Implementing Tables. Module Overview Designing Tables Working with Schemas Creating and Altering Tables.
Module 1: Implementing Active Directory ® Domain Services.
Clifford Dibble Program Manager Microsoft Corporation SESSION CODE: DAT208.
Module 10: Preparing to Monitor Server Performance.
Module 11 Authorizing Users to Access Resources. Module Overview Authorizing User Access to Objects Authorizing Users to Execute Code Configuring Permissions.
Module 1 Introduction to SQL Server® 2008 R2 and its Toolset.
Module 12: Configuring and Managing Storage Technologies
Module 9 Planning and Implementing Monitoring and Maintenance.
Module 6: Administering Reporting Services. Overview Server Administration Performance and Reliability Monitoring Database Administration Security Administration.
Module 14: Advanced Topics and Troubleshooting. Microsoft ® Windows ® Small Business Server (SBS) 2008 Management Console (Advanced Mode) Managing Windows.
Module 5: Managing Content. Overview Publishing Content Executing Reports Creating Cached Instances Creating Snapshots and Report History Creating Subscriptions.
Maintaining and Updating Windows Server 2008 Lesson 8.
SQL Advanced Monitoring Using DMV, Extended Events and Service Broker Javier Villegas – DBA | MCP | MCTS.
MANAGEMENT DATA WAREHOUSE AND DATA COLLECTOR Ian Lanham.
SQL Database Management
Monitoring Windows Server 2012
Performance Management
SQL Server Data Collector From Every Angle
SQL Server Monitoring Overview
Microsoft Dumps Question Answer - Dumps4download
SQL Server on Linux Troubleshooting tips and tricks
The Force Within Management Data Warehouse
Presentation transcript:

Module 18 Monitoring SQL Server 2008 R2

Module Overview Monitoring Activity Capturing and Managing Performance Data Analyzing Collected Performance Data

Lesson 1: Monitoring Activity Overview of Dynamic Management Views and Functions Viewing Activity using Dynamic Management Views Demonstration 1A: Viewing Activity using Dynamic Management Views Working with Activity Monitor in SQL Server Management Studio Demonstration 1B: Working with Activity Monitor in SQL Server Management Studio Working with Reliability and Performance Monitor Working with SQL Server Counters Demonstration 1C: Working with Reliability and Performance Monitor

Overview of Dynamic Management Views and Functions Organized by category Many other categories available CategoryDescription sys.dm_exec_%Execution and Connection sys.dm_os_%SQL OS related information sys.dm_tran_%Transaction Management sys.dm_io_%I/O related information sys.dm_db_%Database scoped information Dynamic Management Objects are virtual views and functions that provide state data for SQL Server systems.

Viewing Activity using Dynamic Management Views Must be referenced using the sys schema Two basic types:  Current status information  Accumulated historical information SELECT s.original_login_name, s.program_name, t.wait_type, t.wait_duration_ms FROM sys.dm_os_waiting_tasks AS t INNER JOIN sys.dm_exec_sessions AS s ON t.session_id = s.session_id WHERE s.is_user_process = 1 AND t.wait_duration_ms > 3000; SELECT * FROM sys.dm_os_wait_stats ORDER BY wait_time_ms DESC; SELECT s.original_login_name, s.program_name, t.wait_type, t.wait_duration_ms FROM sys.dm_os_waiting_tasks AS t INNER JOIN sys.dm_exec_sessions AS s ON t.session_id = s.session_id WHERE s.is_user_process = 1 AND t.wait_duration_ms > 3000; SELECT * FROM sys.dm_os_wait_stats ORDER BY wait_time_ms DESC;

Demonstration 1A: Viewing Activity using Dynamic Management Views In this demonstration, you will see how to use DMVs to view performance information

Working with Activity Monitor in SQL Server Management Studio Shows information about SQL Server Processes, Waits, I/O and expensive Queries Accesses SQL Server through Dynamic Management Objects Requires VIEW SERVER STATE permission Can be used to kill processes that block others Shows information about SQL Server Processes, Waits, I/O and expensive Queries Accesses SQL Server through Dynamic Management Objects Requires VIEW SERVER STATE permission Can be used to kill processes that block others

Demonstration 1B: Working with Activity Monitor in SQL Server Management Studio In this demonstration, you will see:  How to use Activity Monitor to view process information  How to kill a process using Activity Monitor

Working with Reliability and Performance Monitor Used to collect and view system metrics Provides real time monitoring of health and performance counters Creates data collector sets that capture data from different data collectors either on demand or scheduled Key areas to monitor CPU Memory Disk System Network SQL Server Counters Key areas to monitor CPU Memory Disk System Network SQL Server Counters

Working with SQL Server Counters SQL Server exposes objects to Performance and Reliability Monitor  Each object contains one or more counters  Each counter can have one or more instances  Multi-instance counters also provide a total Also available through sys.dm_os_performance_counters ObjectCounterInstance

Demonstration 1C: Working with Reliability and Performance Monitor In this demonstration, you will see how to use Windows Reliability and Performance Monitor

Lesson 2: Capturing and Managing Performance Data Overview of Data Collector Designing a Data Collector Topology Configuring Data Collector Data Collector Security Monitoring Data Collector Demonstration 2A: Configuring Data Collector

Overview of Data Collector  Low overhead data collection  Persistence of diagnostics data  Data retention  Rich reporting  Easy extensibility  Central repository for several SQL Server instances Data Collector is a component of SQL Server that collects capacity planning and performance data over time.

Designing a Data Collector Topology SSIS and SQL Agent jobs are used to send data to the central database SSMS is used to access Reports Data Repository Centralized Data Storage Data Repository Centralized Data Storage Reporting Data Collector Performance Counter SQL Trace T-SQL Data Collector Performance Counter SQL Trace T-SQL Data Collector Performance Counter SQL Trace T-SQL Data Collector Performance Counter SQL Trace T-SQL

Configuring Data Collector Wizard-based Setup Two-step process: 1. Create the Management Data Warehouse 2. Configure Data Collector on all instances to be monitored Plan for enough space in Management Data Warehouse Configuration creates System Data Collection Sets  Data to be collected  Frequency of collection  Retention period Custom Data Collection Sets can be added

Data Collector Security RoleDescription mdw_adminFull access to the management data warehouse mdw_writerWrite and read access. Needed by data collectors mdw_readerRead access. Needed by users accessing Reports RoleDescription dc_adminFull administrator access to the configuration dc_operatorRead and update access to the configuration dc_proxyRead access to the configuration Roles for the Management Data Warehouse: Roles for Configuring the Data Collector:

Monitoring Data Collector Configuration and Log written to msdb  Implemented via stored procedures and SSIS logging features Three logging levels are available Retention is based on collection set retention Logs can be viewed using T-SQL or Log File Viewer

Demonstration 2A: Configuring Data Collector In this demonstration you will see how to configure data collector

Lesson 3: Analyzing Collected Performance Data Overview of Data Collector Reports Disk Usage Report Demonstration 3A: Disk Usage Report Server Activity Report Demonstration 3B: Server Activity Report Query Statistics Report Demonstration 3C: Query Statistics Report

Overview of Data Collector Reports Disk Usage Summary  Trends and details on disk and file usage Query Statistics History  Most expensive queries ranked by: CPU, Duration, Reads, Writes Server Activity History  CPU, Memory, Disk and Network I/O  SQL Server Waits and SQL Server Activity Data Collector provides a series of cross-linked reports on historical data. The reports are visible from within SQL Server Management Studio.

Disk Usage Report  Based on Disk Usage System Data Collection Set T-SQL collector type Not cached, runs every 6 hours by default Stored for 730 days by default

Demonstration 3A: Disk Usage Report In this demonstration, you will see the information that is available in a disk usage report

Server Activity Report Based on Server Activity System Data Collection Set  DMV snapshot and performance counter collector types  Runs every 60 seconds and uploaded every 15 minutes by default  Retained for 14 days by default Provides many sub-reports with detailed information on SQL Server and Windows processes Crossed linked to Query Statistics Reports

Demonstration 3B: Server Activity Report In this demonstration, you will see the information that is available in a server activity report

Query Statistics Report Based on Query Statistics System Data Collection Set  Query activity collector type  Runs every 10 seconds and uploaded every 15 minutes by default  Retained for 14 days by default Expensive queries are gathered including both the query text and the query plan

Demonstration 3C: Query Statistics Report In this demonstration, you will see the information that is available in a query statistics report

Lab 18: Monitoring SQL Server 2008 R2 Exercise 1: Investigating DMVs Exercise 2: Configure Management Data Warehouse Exercise 3: Configure Instances for Data Collection Challenge Exercise 4: Work with Data Collector Reports (Only if time permits) Logon information Estimated time: 45 minutes

Lab Scenario The earlier versions of SQL Server that you have worked with did not include dynamic management functions and views. You have recently read about these and are interested to see how they might be used for collecting performance information. Rather than collecting information separately for each SQL Server instance, you have decided to collect all the performance information to a central server. This will help when dealing with issues that were not reported to the helpdesk at the time they occurred.

Lab Review How can you locate long running queries using the Data Collector reports? When performance counters have multiple instances, how do you view the total for all instances?

Module Review and Takeaways Review Questions Best Practices