© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 DBMS Performance Monitoring.

Slides:



Advertisements
Similar presentations
Monitoring and Testing I/O
Advertisements

Chapter 9. Performance Management Enterprise wide endeavor Research and ascertain all performance problems – not just DBMS Five factors influence DB performance.
Module 13: Performance Tuning. Overview Performance tuning methodologies Instance level Database level Application level Overview of tools and techniques.
Database Performance Tuning and Query Optimization
Lock Tuning. overview © Dennis Shasha, Philippe Bonnet 2001 Sacrificing Isolation for Performance A transaction that holds locks during a screen interaction.
Troubleshooting Dennis Shasha and Philippe Bonnet, 2013.
AOBD 07/08H. Galhardas DBMS Performance Monitoring.
Chapter Physical Database Design Methodology Software & Hardware Mapping Logical Design to DBMS Physical Implementation Security Implementation Monitoring.
What is SDM? SDM : Server and Database Monitoring  SDM is the web-based real-time server and database monitoring and reporting tool  Service Items Server.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 11 Database Performance Tuning and Query Optimization.
1 External Sorting for Query Processing Yanlei Diao UMass Amherst Feb 27, 2007 Slides Courtesy of R. Ramakrishnan and J. Gehrke.
Oracle 10g Database Administrator: Implementation and Administration Chapter 14 Proactive Maintenance.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 11 Database Performance Tuning and Query Optimization.
Chapter 9 Overview  Reasons to monitor SQL Server  Performance Monitoring and Tuning  Tools for Monitoring SQL Server  Common Monitoring and Tuning.
Module 8: Monitoring SQL Server for Performance. Overview Why to Monitor SQL Server Performance Monitoring and Tuning Tools for Monitoring SQL Server.
Executing Explain Plans and Explaining Execution Plans Craig Martin 01/20/2011.
Introduction to Databases Chapter 8: Improving Data Access.
C-Store: Column Stores over Solid State Drives Jianlin Feng School of Software SUN YAT-SEN UNIVERSITY Jun 19, 2009.
Database Systems: Design, Implementation, and Management Tenth Edition Chapter 11 Database Performance Tuning and Query Optimization.
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 10 Database Performance Tuning and Query Optimization.
2 Copyright © 2006, Oracle. All rights reserved. Performance Tuning: Overview.
Physical Database Design & Performance. Optimizing for Query Performance For DBs with high retrieval traffic as compared to maintenance traffic, optimizing.
March 19981© Dennis Adams Associates Tuning Oracle: Key Considerations Dennis Adams 25 March 1998.
DBSQL 14-1 Copyright © Genetic Computer School 2009 Chapter 14 Microsoft SQL Server.
MySQL. Dept. of Computing Science, University of Aberdeen2 In this lecture you will learn The main subsystems in MySQL architecture The different storage.
© Dennis Shasha, Philippe Bonnet – 2013 Communicating with the Outside.
Oracle9i Performance Tuning Chapter 1 Performance Tuning Overview.
©Silberschatz, Korth and Sudarshan13.1Database System Concepts Chapter 13: Query Processing Overview Measures of Query Cost Selection Operation Sorting.
Insert, Update & Delete Performance Joe Chang
Oracle Tuning Considerations. Agenda Why Tune ? Why Tune ? Ways to Improve Performance Ways to Improve Performance Hardware Hardware Software Software.
Oracle Tuning Ashok Kapur Hawkeye Technology, Inc.
Learningcomputer.com SQL Server 2008 – Profiling and Monitoring Tools.
Oracle9i Performance Tuning Chapter 12 Tuning Tools.
© Dennis Shasha, Philippe Bonnet 2001 Log Tuning.
SCUHolliday - COEN 17814–1 Schedule Today: u Query Processing overview.
CS Operating System & Database Performance Tuning Xiaofang Zhou School of Computing, NUS Office: S URL:
Large Data Operations Joe Chang
By Shanna Epstein IS 257 September 16, Cnet.com Provides information, tools, and advice to help customers decide what to buy and how to get the.
1 Chapter 10 Joins and Subqueries. 2 Joins & Subqueries Joins – Methods to combine data from multiple tables – Optimizer information can be limited based.
CPSC 404, Laks V.S. Lakshmanan1 External Sorting Chapter 13: Ramakrishnan & Gherke and Chapter 2.3: Garcia-Molina et al.
Chapter 12 Query Processing (1) Yonsei University 2 nd Semester, 2013 Sanghyun Park.
© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 DBMS Performance Monitoring.
1 Chapter 13 Parallel SQL. 2 Understanding Parallel SQL Enables a SQL statement to be: – Split into multiple threads – Each thread processed simultaneously.
Deep understanding of DB2 and Snapshots monitoring and Administrative view Sharad D. Pawar ACI Payment system.
ASEMON JEAN-PAUL MARTIN May 2015.
MISSION CRITICAL COMPUTING Siebel Database Considerations.
Query Optimization CMPE 226 Database Systems By, Arjun Gangisetty
1 Copyright © 2005, Oracle. All rights reserved. Following a Tuning Methodology.
© Dennis Shasha, Philippe Bonnet 2001 Log Tuning.
Computing & Information Sciences Kansas State University Wednesday, 08 Nov 2006CIS 560: Database System Concepts Lecture 32 of 42 Monday, 06 November 2006.
Lock Tuning. Overview Data definition language (DDL) statements are considered harmful DDL is the language used to access and manipulate catalog or metadata.
External Sorting. Why Sort? A classic problem in computer science! Data requested in sorted order –e.g., find students in increasing gpa order Sorting.
Chapter 13: Query Processing
Database Systems, 8 th Edition SQL Performance Tuning Evaluated from client perspective –Most current relational DBMSs perform automatic query optimization.
CS422 Principles of Database Systems Buffer Management Chengyu Sun California State University, Los Angeles.
Troubleshooting Dennis Shasha and Philippe Bonnet, 2013.
Execution Plans Detail From Zero to Hero İsmail Adar.
SQL Advanced Monitoring Using DMV, Extended Events and Service Broker Javier Villegas – DBA | MCP | MCTS.
Proactive Index Design Using QUBE Lauri Pietarinen Courtesy of Tapio Lahdenmäki November 2010 IDUG 2010.
© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 DBMS Performance Monitoring.
Database Performance Tuning &
SQL Server Monitoring Overview
Database Performance Tuning and Query Optimization
Hustle and Bustle of SQL Pages
Program Testing and Performance
Troubleshooting Techniques(*)
Index Tuning Additional knowledge.
Query Processing CSD305 Advanced Databases.
Chapter 11 Database Performance Tuning and Query Optimization
Presentation transcript:

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 DBMS Performance Monitoring

overview

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 To Index or not to index? select c_name, n_name from CUSTOMER join NATION on c_nationkey=n_nationkey where c_acctbal > 0 Which plan performs best? (nation_pk is an non-clustered index over n_nationkey, and similarly for acctbal_ix over c_acctbal)

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 Non-clustering indexes can be trouble For a low selectivity predicate, each access to the index generates a random access to the table – possibly duplicate! It ends up that the number of pages read from the table is greater than its size, i.e., a table scan is a better way Table ScanIndex Scan 5 sec 143,075 pages 6,777 pages 136,319 pages 7 pages 76 sec 272,618 pages 131,425 pages 273,173 pages 552 pages CPU time data logical reads data physical reads index logical reads index physical reads

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 Profiling a Query’s Execution A query was found critical but its plan looks okay. What’s going on? Put it to run. (We just did in the previous example.) Profiling it would determine the quantity of the resources used by a query and assessing how efficient this use was Resources –DBMS subsystems: cache, disk, lock, log –OS raw resources: CPU

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 Performance Monitors to Profiling Queries Access or compute performance indicators’ values at any time Many, many flavors –Generic (all indicators) or Specific (indicators of a given subsystem or a given query) –Snapshot, Continuous, or Alarm modes –Textual or Graphical

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 An example Performance Monitor (query level) Details of buffer and CPU consumption on a query’s report according to DB2’s Benchmark tool Similar tools: MSSQL’s SET STATISTICS switch and Oracle’s SQL Analyze Tool Statement number: 1 select C_NAME, N_NAME from DBA.CUSTOMER join DBA.NATION on C_NATIONKEY = N_NATIONKEY where C_ACCTBAL > 0 Number of rows retrieved is: Number of rows sent to output is: 0 Elapsed Time is: seconds … Buffer pool data logical reads = Buffer pool data physical reads = Buffer pool data writes = 0 Buffer pool index logical reads = Buffer pool index physical reads = 552 Buffer pool index writes = 0 Total buffer pool read time (ms) = Total buffer pool write time (ms) = 0 … Summary of Results ================== Elapsed Agent CPU Rows Rows Statement # Time (s) Time (s) Fetched Printed Statement number: 1 select C_NAME, N_NAME from DBA.CUSTOMER join DBA.NATION on C_NATIONKEY = N_NATIONKEY where C_ACCTBAL > 0 Number of rows retrieved is: Number of rows sent to output is: 0 Elapsed Time is: seconds … Buffer pool data logical reads = Buffer pool data physical reads = Buffer pool data writes = 0 Buffer pool index logical reads = Buffer pool index physical reads = 552 Buffer pool index writes = 0 Total buffer pool read time (ms) = Total buffer pool write time (ms) = 0 … Summary of Results ================== Elapsed Agent CPU Rows Rows Statement # Time (s) Time (s) Fetched Printed

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 An example Performance Monitor (system level) An IO indicator’s consumption evolution (qualitative and quantitative) according to DB2’s System Monitor Similar tools: Window’s Performance Monitor and Oracle’s Performance Manager

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 Investigating High Level Consumers: Summary Find critical queries Found any? Investigate lower levels Answer Q1 over them Overcon- sumption? Tune problematic queries yes no

© Dennis Shasha, Alberto Lerner, Philippe Bonnet 2004 Investigating Primary Resources Answer question 3: “Are there enough primary resources available for a DBMS to consume?” Primary resources are: CPU, disk/controllers, memory, and network Analyze specific OS-level indicators to discover bottlenecks. A system-level Performance Monitor is the right tool here

summary