1.

Slides:



Advertisements
Similar presentations
DB-Time-based Oracle Performance Tuning: Theory and Practice
Advertisements

Presentation Date Top Down Performance Management with OEM Grid Control Or how I learned to stop worrying and love OEM Grid Control 10/1/2010 John Darrah.
Copyright © SoftTree Technologies, Inc. DB Tuning Expert.
Module 13: Performance Tuning. Overview Performance tuning methodologies Instance level Database level Application level Overview of tools and techniques.
1 Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Royal London Group A group of specialist businesses where the bottom line is always financial sense Oracle Statistics – with a little bit extra on top.
MCTS GUIDE TO MICROSOFT WINDOWS 7 Chapter 10 Performance Tuning.
The following is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any.
A Java Architecture for the Internet of Things Noel Poore, Architect Pete St. Pierre, Product Manager Java Platform Group, Internet of Things September.
Managing Change with Real Application Testing and Snapshot Standby Barry Hodges Senior Solution Architect, Sales Consulting, Oracle NZ.
Automatic Performance Diagnosis and Tuning in Oracle 10g Graham Wood Oracle Corporation.
Oracle 10.2 for z/OS and z/Linux Performance Update.
12 Copyright © 2005, Oracle. All rights reserved. Proactive Maintenance.
The Self-managing Database: Automatic Performance Diagnosis Graham Wood Kyle Hailey Oracle Corporation Session id:
Chapter 14 Chapter 14: Server Monitoring and Optimization.
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. | Oracle SQL Developer What’s New in Version 4.1 Jeff Smith
Oracle 10g Database Administrator: Implementation and Administration Chapter 14 Proactive Maintenance.
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. | 2 Hidden Gems of APEX David Gale Software Engineer Oracle Application Express November,
Chapter 9 Overview  Reasons to monitor SQL Server  Performance Monitoring and Tuning  Tools for Monitoring SQL Server  Common Monitoring and Tuning.
Oracle 11g Real Application Testing: Avoiding Performance Regressions with SQL Performance Analyzer Khaled Yagoub, Pete Belknap, Benoit Dageville, Karl.
© 2009 Oracle Corporation. S : Slash Storage Costs with Oracle Automatic Storage Management Ara Vagharshakian ASM Product Manager – Oracle Product.
Effective Methods for Analyzing Altiris Performance Sam Saffron | Development Manager | Altiris John Epeneter | Product Manager | Altiris Monitoring.
Application Express 4.1 New Features Hilary Farrell, Principal Member of Technical Staff, Oracle.
Maintaining a Microsoft SQL Server 2008 Database SQLServer-Training.com.
12 Copyright © 2004, Oracle. All rights reserved. Automatic Management.
Database Advisors Automatic Database Diagnostic Monitor ( ADDM )
Introduction and simple using of Oracle Logistics Information System Yaxian Yao
12 Copyright © 2007, Oracle. All rights reserved. Database Maintenance.
1Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8 Reporting from Contract.
15 Copyright © 2004, Oracle. All rights reserved. Proactive Maintenance.
MCTS Guide to Microsoft Windows 7
2 Copyright © 2006, Oracle. All rights reserved. Performance Tuning: Overview.
Oracle E-Business Suite Order Management: Presenting the HTML and Mobile User Experience Durgaprasad Bodapati Director, Product Management Bhavana Sharma.
Oracle Application Express 3.0 Joel R. Kallman Software Development Manager.
Michael Sit Solution Specialists Manager Oracle Corporation.
Oracle Patching and Maintenance A practical guide for System Administrators October 2009.
1 Robert Wijnbelt Health Check your Database A Performance Tuning Methodology.
Hadoop 2 cluster with Oracle Solaris Zones, ZFS and unified archives Orgad Kimchi - Principal Software Engineer September 29, 2014 Oracle Confidential.
1Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8 Contract Management.
The Self-Managing Database: Guided Application and SQL Tuning Mohamed Ziauddin Consulting Member of Technical Staff Oracle Corporation Session id:
Simplified SQL Performance Management in Oracle Database 11g Pete Belknap.
SQL Tuning made much easier with SQLTXPLAIN (SQLT) Mauro Pagano Senior Principal Technical Support Engineer Oracle Confidential – Internal/Restricted/Highly.
1 Session S317114: What Else Can I Do with System and Session Performance Data Thomas Kyte
Oracle9i Performance Tuning Chapter 12 Tuning Tools.
Quick Tips for Database Performance Tuning Sergey Koltakov Kurt Engeleiter Product Manager.
1. S318417: OAUG SysAdmin SIG Angelo Rosado, Oracle Senior Product Manager Kenneth Baxter, Oracle Strategy Product Manager Biju Mohan, Oracle Principal.
Continuous DB integration testing with RAT „RATCOIN”
1 Oracle Enterprise Manager Slides from Dominic Gélinas CIS
Power at Your Fingertips –Overlooked Gems in Oracle EM John Sheaffer Principal Sales Consultant – Oracle Corporation.
Enterprise Database Administration & Deployment SIG ▪ 313M ▪ Sept 29, 2005 ▪ 10:15 AM SQL Server 2005 Performance Diagnosis and Tuning using SQL Tools.
10G - New Manageability Features Presented by Lenka Vanek
Troubleshooting SQL Server Performance: Tips &Tools Amit Khandelwal.
The Self-managing Database: Proactive Space and Schema Object Management Amit Ganesh Director, Data, Space and Transaction Processing Oracle Corporation.
Rajesh Bhat Director, PLM Analytics Applications
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Proactive Recommendations Public Sector SIG Vanha Le Principal Technical Support.
#.1 Average Active Sessions (AAS) The Golden Metric ? Kyle Hailey
Log Shipping, Mirroring, Replication and Clustering Which should I use? That depends on a few questions we must ask the user. We will go over these questions.
An overview of AWR, ASH and ADDM. Learning About AWR Real-World Performance Day with Tom Kyte The Independent Oracle Users Groups presents “A Day of Real-World.
Troubleshooting Dennis Shasha and Philippe Bonnet, 2013.
Closing the Query Processing Loop in Oracle 11g Allison Lee, Mohamed Zait.
Session Name Pelin ATICI SQL Premier Field Engineer.
Introduction.
Data, Space and Transaction Processing
How To Pass Oracle 1z0-060 Exam In First Attempt?
One Picture is Worth a Thousand Words
Get Verified Oracle 1z0-062 Study Material - Oracle 1z0-062 Exam Dumps PDF Realexamdumps.com
OpenWorld 2018 Accelerate Your Success on Oracle Cloud Infrastructure with Applications Unlimited Support Viviana Tilita Senior Technical Support Engineer.
JD Edwards Support and Oracle Cloud Infrastructure: A Successful Path to Oracle Cloud
The New Oracle Monitoring and Advisory Service for Applications Unlimited Michael Soulier Senior Director Applications Customer Support, PeopleSoft October.
Targeting Wait Statistics with Extended Events
Presentation transcript:

1

Kurt Engeleiter Product Manager Using Automatic Workload Repository for Database Tuning: Tips for Expert DBAs Kurt Engeleiter Product Manager

The following is intended to outline our general product direction The following is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle.

Oracle Enterprise Manager Top-Down, Integrated Application Management Complete, Open, Integrated Management for Oracle Technologies Deep, Optimized, Best of Breed Database, Middleware, Packaged Applications, Physical and Virtual Infrastructure Business Centric, Top Down Application Management Complete Lifecycle Management Scalable Grid and Cloud Management Manage many as one I would like to start with a quick review of Oracle Enterprise Manager. For all of you here in this room, applications are key IT and enterprise assets. If you are on the business side, they provide productivity and automation for your business processes. If you are on the IT side, well, you are constantly watching over them – as a DBA, or as an application administrator etc. and we know hard a job that is. Oracle Enterprise Manager provides you a unique top-down approach for managing applications. Lets take a quick look to see why you should care. Oracle Enterprise Managers provides the most comprehensive, deep, and best of breed management for Oracle products. It manages the complete IT stack - all the way from packaged applications (EBS, Siebel, PSFT,etc.) to middleware and database in both physical and virtual environments. Oracle Enterprise Manager has unparalleled and deep understanding of Oracle technologies, which allows us to provide intelligent and unique solutions designed to maximize quality of service and minimize cost and complexity. No body understands Oracle better than Oracle Enterprise Manager! While Oracle Enterprise Manager’s core strength is managing Oracle ecosystem, it is not a closed solution. A rich set of plug-ins allow it to monitor and manage large number of non-Oracle products – including MS SQL Server, IBM Websphere, EMC Symmetrix, F5 BIG-IP, etc. Oracle Enterprise Manager also features a rich set of cross-tier management solutions spanning applications, middleware, database and infrastructure layers. This enables a unique "top-down" management approach which allows Information Technology (IT) departments to focus on what matters to the business - greater agility, better service quality and lower operational costs. Using Oracle Enterprise Manager, you can manage your applications from a top-down perspective - from monitoring service levels to proactively isolating business exceptions before they escalate, and remediating issues at any level of the IT stack. The breadth of management solution is another hallmark of Enterprise Manager. It provides a complete and integrated lifecycle management solution, including testing, provisioning, patching, monitoring, day to day administration, performance and configuration management. Finally, Oracle Enterprise Manager is a key enabler of Oracle’s Grid and Cloud Computing solutions. It provides capabilities to manage large number of systems with the same ease of use as a single system. Groups of machines and targets can be managed as a single entity (using its systems, services functionality), thereby providing a scalable management framework to make the concept of grid/cloud computing a practical reality.

<Insert Picture Here> Agenda <Insert Picture Here> Automatic Workload Repository Infrastructure Out of the box AWR reports Active Reports 5

Automatic Workload Repository (AWR ) Built-in, automatic performance statistics data warehouse ADDM finds top problems MMON SYSAUX AWR Data BG In-memory statistics … 7:00 a.m. Snapshot 1 BG 8:00 a.m. Eight days AWR Statistics Snapshot 2 ASH 9:00 a.m. FG 10:00 a.m. Snapshot 3 P … Snapshot 4 FG SGA V$ DBA_HIST% DBA

Wall-Clock (Elapsed) Time Fundamental Concepts DB Time Total time in database calls by foreground sessions Includes CPU time, IO time and non-idle wait time DB Time <> response time Total DB time = sum of DB time for all active sessions Goal: To Reduce Total DB time Active Session Session currently spending time in a database call, i.e., accruing DB time Average Active Sessions Average Active Sessions is a key metric for measuring DB load = Wall-Clock (Elapsed) Time DB Time

Wall-Clock (Elapsed) Time Multiple Sessions Total DB Time = Sum of DB Time Over All Sessions Avg. Active Sessions = Sum of Avg. Activity Over All Sessions Wall-Clock (Elapsed) Time Total Database Time = t At time t we have 2 active sessions User 1 User 2 User 3 User n TIME = time spent in database

AWR Data 9 Time Model Wait Model SQL statement statistics OS Stats Commit Time Model v$sys_time_model => dba_hist_sys_time_model DB Time Automatic Tracking of Operation Times Overall parse time (hard, soft, failed,..) SQL, PLSQL and Java overall execution times Wait Model v$system_event => dba_hist_system_event Wait Events Categorized Based On Solution Area More than 900 different wait events. 12 wait classes (Application, Concurrency..) SQL statement statistics v$sqlstats => dba_hist_sqlstat Resource Usage: Executions, Physical Reads, Physical Writes Efficient Top SQL identification using deltas in the kernel OS Stats v$osstat => dba_hist_osstat CPU + Memory CPU Application User I/O 9

AWR Data Snapshots DBA_HIST_SNAPSHOT Tracks Snapshots in the AWR When querying AWR, always join to other tables to constrain the time frame 10

AWR Data 11

Active Session History (ASH) ASH is session level data Active sessions are sampled and persisted in-memory Sampling interval = 1 second V$ACTIVE_SESSION_HISTORY Foreground and background sessions are sampled On-disk persistence DBA_HIST_ACTIVE_SESS_HISTORY ASH is a system-wide trace of what happened ASH is a many-dimensional FACT table Dimensions are V$SESSION columns Fact is that DB time was accumulating over these dimensions

Query for Tom Kyte Books Active Session History (ASH) Query for Tom Kyte Books Browse and Read Reviews Add item to cart Checkout using ‘one-click’ DB Time WAITING State db file sequential read qa324jffritcf 213 7:38:26 Event SQL ID Module SID Time CPU aferv5desfzs5 Get review id 7:42:35 log file sync abngldf95f4de One click 7:52:33 buffer busy wait hk32pekfcbdfr Add to cart 7:50:59 Book by author

ASH Session State Objects Every snapshot or out of space AWR V$SESSION V$SESSION_WAIT V$ACTIVE_SESSION_HISTORY DBA_HIST_ACTIVE_SESS_HISTORY Session State Objects Every snapshot or out of space AWR MMON Lite (MMNL) The CBS Method (“Click on the Big Stuff method”) Shows ASH samples for the selected wait class Answers the “who” and “what” of the problem Who is slowing up the system? What is that person doing? Circular buffer in SGA

AWR and ASH in Enterprise Manager The CBS Method (“Click on the Big Stuff method”) Shows ASH samples for the selected wait class Answers the “who” and “what” of the problem Who is slowing up the system? What is that person doing?

Top Activity

SQL Details

Demo Active Session Widget

<Insert Picture Here> Agenda <Insert Picture Here> Automatic Workload Repository Infrastructure Out of the box AWR reports Active Reports 19

AWR Reporting Resources Enterprise Manager is the preferred way to view and analyze AWR and ASH data In addition, predefined AWR html reports are provided in each Oracle database release Each report has a specific function and use case The following slides show the major reports and their use cases give details – what are each report 20

AWR Reporting Resources Available in Enterprise Manager $ORACLE_HOME/rdbms/admin REPORT NAME SQL Script Automatic Workload Repository Report awrrpt.sql Automatic Database Diagnostics Monitor Report addmrpt.sql ASH Report ashrpt.sql AWR Diff Periods Report awrddrpt.sql AWR Single SQL Statement Report awrsqrpt.sql AWR Global Report awrgrpt.sql AWR Global Diff Report awrgdrpt.sql give details – what are each report 11gR2 21

How do I read an AWR report?

AWR Report The AWR report is the most well known performance report. Oracle tuning professionals frequently start their analysis with this report. AWR report contains much data – but contains no concrete recommendations for action. 23

Tip: Check ADDM Report When Viewing AWR Report When viewing AWR report, always check corresponding ADDM report for actionable recommendations ADDM is a self diagnostic engine designed from the experience of Oracle’s best tuning experts Analyzes AWR data automatically after an AWR snapshot Makes specific performance recommendations Consistent – never has a ‘bad’ day ADDM also tells you what is NOT a problem ADDM doesn’t have ‘bad’ days – always consistently on. 24

ADDM Report ADDM lists the tuning opportunities with the highest benefit. ADDM makes specific, actionable recommendations. ADDM also lists areas of the system that are performing well – that don’t need tuning. 25

ADDM Impact Breakdown In Oracle Database 11g Release 2, ADDM can break down the impact of it’s findings by several dimensions including service, and session. 26

Demo ADDM

AWR Global Report - RAC RAC AWR Report Report rewritten and renamed in Oracle Database 11.2. spawrrac.sql => awrgrpt.sql All statistics from AWR placed in comparative format, along with sums, averages and standard deviations, making it easy to compare performance of RAC nodes. 28

AWR Global Report – RAC (cont.) In addition to all the data in a single node AWR report, the AWR Global report includes RAC specific data on global cache and interconnect performance. 29

My database was running fine yesterday but it is really slow today My database was running fine yesterday but it is really slow today? What has changed?

Tip: Use AWR Compare Periods Report to Identify Changes in Database Performance awrddrpt.sql – single instance awrgdrpt.sql - RAC Compares database performance over two time periods Good for identifying what changed in performance Tip: Save AWR snapshots of time periods with good performance for reference Example: Overall system performance resulting from database upgrade 31

AWR Global Compare Periods Report Compares global RAC performance for two time ranges This report compares the performance of a two node RAC system, before and after an upgrade from Oracle Database 11.1.0.7 to Oracle Database 11.2. 32

AWR Global Compare Periods Report (cont.) The Load Profile shows a reduction in DB Time per second and per transaction after the upgrade – overall performance has improved. The upgrade was a success. 33

Comparative Performance Analysis with AWR Baselines AWR Baseline contains a set of AWR snapshots for an “interesting or reference” period of time Baseline are key for performance tuning to guide set alert thresholds monitor performance compare advisor reports User-specifiable, schedulable, e.g.: last Thanksgiving period every Monday 10am-noon for 4 Mondays Automatically captures 8-day moving window baseline for week to week comparisons (default) Actual Normal AWR Baseline if spiky performance graph – ash can be used to drill down time 34

A user complains that his session seemed to hang for a few minutes A user complains that his session seemed to hang for a few minutes. What happened?

Tip: Use ASH for Targeted Performance Diagnostics AWR snapshots and reports cover entire system Transient events can be averaged over a snapshot and be non-obvious from an AWR report ASH can be used for examining: Targeted time range A specific session service wait_class client_id SQL_ID A targeted time range in combination with the above if spiky performance graph – ash can be used to drill down 36

ASH Report Click on ‘Run ASH Report’ button from performance page Select time range and dimension to report on replace these ash reports with something else 37

ASH Report: ASH Report of a single session for a 5 minute period The session accounted for 52% of database activity for the time period The session spent 64% of the time in a concurrency wait event, 36% on CPU. There is clearly some opportunity for tuning. replace these ash reports with something else 38

Has my SQL statement’s performance changed over time?

AWR Individual SQL Report Plan Statistics AWR Report for a particular SQL Statement -awrsqrpt.sql Useful for researching individual SQL statement performance over time Example: Single SQL statement, before and after tuning CPU Time per execution substantially decreased – tuning was successful. Before tuning After tuning

Migrating AWR Data Why migrate AWR data? To offload analysis from production database To preserve data longer than the production default retention period To do multi-database comparative analysis Scripts are located in $ORACLE_HOME/rdbms/admin Action SQL Script Extract data from AWR into a datapump file awrextr.sql Load data from datapump file created by awrextr.sql into a database awrload.sql

<Insert Picture Here> Agenda <Insert Picture Here> Automatic Workload Repository Infrastructure Out of the box AWR reports Active Reports 42

Tip: Use Real-Time SQL Monitoring And Active Reports Automatically monitors long running SQL Enabled out-of-the-box with no performance impact Monitors each SQL execution Exposes monitoring statistics Global execution level Plan operation level Parallel Execution level Can be saved or emailed as an ‘Active Report’

Demo Active Reports

AWR contains vast amounts of database performance data Conclusion AWR contains vast amounts of database performance data Enterprise Manager displays a comprehensive view and analysis of that data Standard reports can provide additional insights Use the right report for the right problem Active reports are a useful new tool for the Oracle database professional 45

Oracle Helps You Maximize Customer Value Avoids online revenue losses up to 25% Cuts configuration management effort by 90% Saves weeks on application testing time Replaces manual tools with automation; saves time by 50% Deploys SOA infrastructure 92% faster Saves 80% time and effort for managing Databases Improves IT productivity by 25% Drives asset utilization up by 70% Reduces Database testing time by 90% Reduces provisioning effort by 75% Saves $1.9 million with Oracle Enterprise Manager Saves $170,000 per year with Oracle Enterprise Manager Delivers 24/7 uptime with Oracle Enterprise Manager Cuts application testing from weeks to hours Reduces critical patching time by 80% Many more customers report that Oracle Enterprise Manager helps them to maximize their IT investments. This is an expanded list of customers including some of the cases we just reviewed. You can review these in more detail by visiting oracle.com/enterprisemanager. Each one has an in-depth profile (click on logo in presentation mode) on how their implementation of Oracle Enterprise Manager helped them maximize the value of their IT investment and reduce the overall costs. As you can see, we have examples from a wide variety of different industries and businesses, such as Banking, Telcos, Commercial, Pharamaceuticals, Education, Hotels, Retail, Insurance, and more.

Additional Oracle Enterprise Manager sessions Wednesday, Oct. 14 Location 11:45 a.m.- Performance-Testing Oracle E-Business Suite: Tips and Tricks from Oracle Experts 11:45 a.m.- Oracle Enterprise Manager: Monitoring and Security Best Practices 11:45 a.m.- Upgrade Case Study: Database Replay, Snapshot Standby, and Plan Baselines Moscone S. Room 305 Moscone S. Room 303 Moscone S. Room 301 1:45 p.m.- Quick Tips for Database Performance Tuning 5:00 p.m.- SQL Gone Wild: Taming Bad SQL the Easy Way (or the Hard Way) 5:00pm Oracle Enterprise Manager: Beyond the Basics: Getting More from Oracle Enterprise Manager Moscone S. Room 104 Moscone S. Room 102

Additional Oracle Enterprise Manager sessions Thursday, Oct. 15 Location 10:30 a.m.Everyone Is Applying CPUs (Critical Patch Updates), Right? 10:30 am DBA’s New Best Friend: Oracle Database 10g and Oracle Database 11g SQL Performance Analyzer Moscone S. Room 303 Moscone S. Room 102 12:00 p.m. Worry-Free Application Upgrade Using Oracle Change Management Pack 1:30pm Dell IT's Implementation of Oracle Enterprise Manager Patch Provisioning Moscone S. Room 306

49