Automatic Workload Repository: Soup to Nuts. Graham Wood Doug Burns

Similar documents
Table of Contents. Instructions and Guidelines. Slides Graphic Resources. Slides Branded Presentation Template.

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

Anthony AWR report INTERPRETATION PART I

Agenda. Combining Rules & Selectors Classes, IDs and DIVs

Brand identity design. Professional logo design + Branding guidelines + Stationery Designed by JAVIER

Katharina Römer Principal Sales Consultant STCC Stuttgart ORACLE Deutschland GmbH

OracleMan Consulting

Creating An Effective Academic Poster. ~ A Student Petersheim Workshop

Oracle Database 12c Performance Management and Tuning

cosmos a tech startup

City of Literature Branding

Oracle 10g Self-Management Framework Internals: Exploring the Automatic Workload Repository. Open World September 2005

Intermediate District 288. Brand Manual. Visual Identity Guide

FOR THOSE WHO DO. Lenovo Annual Report

EZY Intellect Pte. Ltd., #1 Changi North Street 1, Singapore

Connected TV Applications for TiVo. Project Jigsaw. Design Draft. 26 Feb 2013

Oracle Database 12c: Performance Management and Tuning

Whitepaper. Call to Action

TUSCALOOSA CITY SCHOOLS Graphic Standards and Logo Use Guide

Formatting Theses and Papers using Microsoft Word

BOWIE FARMERS MARKET. Anne Bontogon Campaign Bowie Farmers Market

TITLE. Tips for Producing a Newsletter IN THIS ISSUE

Gestures: ingsa GESTURES

The POGIL Project Publication Guidelines

Divs, Classes & IDs. Web Development

Ghislain Fourny. Big Data 2. Lessons learnt from the past

Version 1.4 March 15, Notes Bayer- Kogenate 2010 WFH Microsoft Surface Project (HKOG-39563) Information Architecture Wireframes

PERFORMANCE TUNING TRAINING IN BANGALORE

Oracle Database 11g: Performance Tuning DBA Release 2

Windstream Tableau Brings Sales and Marketing Together

TITLE SUBTITLE Issue # Title Subtitle. Issue Date. How to Use This Template. by [Article Author] Article Title. Page # Article Title.

Oralogic Education Systems

Compassion. Action. Change.

template guidelines. 1. Visual identity 2. How to build an

TITLE - Size 16 - Bold

MKA PLC Controller OVERVIEW KEY BENEFITS KEY FEATURES

Example project Functional Design. Author: Marion de Groot Version

Brand Guidelines MAY 2016

FARÉCLA TRADE BRAND GUIDELINES

Timon Hazell, LEED AP Senior BIM Engineer. Galen S. Hoeflinger, AIA BIM Technologist Manager

2010 (c)2013 OraPub, Inc. This presentation was given by Craig Shallahamer at the NoCOUG conference on 15-AUG-2013.

In the Oracle Database 12c: Performance Management and

Oracle Database 11g: Performance Tuning DBA Release 2

Visual identity guideline. BrandBook BLOOMINGFELD. Brandbook 2016.

1Z Oracle Database Performance and Tuning Essentials 2015 Exam Summary Syllabus Questions

Performance Problems

A Road To Better User Experience. The lonely journey every front-end developer must walk.

Oracle Database 10g The Self-Managing Database

Colors. F0563A Persimmon. 3A414C Cobalt. 8090A2 Slate Shale. C4CDD6 Alloy Coal. EFF3F5 Silver. EDF3F9 Horizon.

Learning Objectives : This chapter provides an introduction to performance tuning scenarios and its tools.

Brand guidelines. Introduction These guidelines define the basic elements of the Concept Smoke Screen brand.

Copyright 2018, Oracle and/or its affiliates. All rights reserved.

Paper Template for INTERSPEECH 2018

The L A TEX Template for MCM Version v6.2

<Insert Picture Here> DBA Best Practices: A Primer on Managing Oracle Databases

BOOTSTRAP AFFIX PLUGIN

<Insert Picture Here> DBA s New Best Friend: Advanced SQL Tuning Features of Oracle Database 11g

RAC Performance Monitoring and Diagnosis using Oracle Enterprise Manager. Kai Yu Senior System Engineer Dell Oracle Solutions Engineering

Abstract. Author summary. Introduction

VISUAL IDENTITY STARTER KIT FOR ENSURING OUR COMMUNICATIONS ARE COHESIVE, CONSISTENT AND ENGAGING 23 OCTOBER 2008

Certified Organisation logo guidelines. Version 1.0 April 2018

Custom Performance Reporting Changes in Oracle 10g. Brian Doyle BEZ Systems VP, Product Service

Taming the AWR Tsunami

VISUAL. Standards Guide

Tuning slow queries after an upgrade

Index. ChannelEngine. Our users. Product. Writing. Tone-of-voice. Colors. Color Combinations. Typography - Fonts. Typography - Rules. Logo.

Optimizing Tableau Server for High Availability

WRAS WIAPS BRAND GUIDELINES 2015

Reflex Skip Julien Verlaguet

POSTER PRESENTATION GUIDELINES

This page presents most of typographical aspects of JA Drimia. Make your readers happy with great Typography and User Experience!

Unit 20 - Client Side Customisation of Web Pages WEEK 5 LESSON 6 DESIGNING A WEB-SITE

TABLE OF CONTENTS LOGO THE WE LOVE ENGINES LOGO THE GLOBAL COVERAGE AND WIX INSTITUTE LOGOS COLOURS FONTS ICONS THE 2017 CAMPAIGN SLOGAN KEY VISUALS

The Next Big Thing Prepared for Meeting C

Posters guidelines APRIL 2017

<Insert Picture Here> Maximizing Database Performance: Performance Tuning with DB Time

Personal brand identity desigend by JAVIER

Oracle 1Z0-417 Exam Questions and Answers (PDF) Oracle 1Z0-417 Exam Questions 1Z0-417 BrainDumps

Presentation title placeholder, can be two lines Presentation subtitle placeholder. Date placeholder

The rjlpshap class. Robert J Lee July 9, 2009

End-to-end Management with Grid Control. John Abrahams Technology Sales Consultant Oracle Nederland B.V.

Teach Yourself Microsoft Publisher Topic 2: Text Boxes

Oracle Database 11g : Performance Tuning DBA Release2

<Insert Picture Here>

Brand identity guidelines

Faculty Web Pages: Editing the Template Prepared by Tamara Fudge, June 2008

NATURAL BUILDING TECHNOLOGIES Document: Feedback Sheet Revision: A Date: 13/07/16 Queries:

CSE 154 LECTURE 5: FLOATING AND POSITIONING

Making the New Notes. Christoph Noack OpenOffice.org User Experience Max Odendahl OpenOffice.org Development Christian Jansen Sun Microsystems

Oracle 1Z0-054 Exam Questions and Answers (PDF) Oracle 1Z0-054 Exam Questions 1Z0-054 BrainDumps

Word Processing Fundamentals

Demystifying SQL Tuning: Tips and Techniques for SQL Experts

This page presents most of typographical aspects of JA Teline iii. Make your readers happy with great Typography and User Experience!

Identity Guidelines Version_1

Transforming IT-speak:

COLORS COLOR USAGE LOGOS LOCK UPS PHOTOS ELEMENTS ASSETS POWERPOINT ENVIRONMENTAL COLLATERAL PROMO ITEMS TABLE OF CONTENTS

Creating Websites without Code. Jesse Clark, Webmaster University of Northern Colorado

Brand guidelines These guidelines are a work in progress.

Brand Guide. Last Revised February 9, :38 PM

Oracle Database 11g: Self-Managing Database - The Next Generation

Transcription:

1

Automatic Workload Repository: Soup to Nuts Graham Wood Doug Burns

Doug Burns Background Independent Oracle Consultant Oracle ACE Director Oak Table Network The guy with the plushy toys http://oracledoug.com 3

Graham Wood Background Performance guy Joined Oracle in 1986 Architect in Oracle RDBMS dev Created Statspack and AWR Real World Performance Group Oak Table Member 4

Real World Performance at OOW13 Why is my SQL slow? Mon 13:45 Moscone South 102 Dilemmas in Middleware Tue 15:45 Moscone South 102 What Is Big Data, and What Makes It Big? Wed 13:15 Moscone South 300 5

Program Agenda Basics AWR Reports Case Study Administration and Diagnostics Conclusions 6

Program Agenda Basics AWR Reports Case Study Administration and Diagnostics Conclusions 7

AWR Basics Is this the Soup? Repository for snapshots of Oracle performance data Introduced with Oracle 10g Licensed as part of Diagnostic Pack On by default Self-managing 8

AWR Basics Snapshots Capture performed by MMON process Captures data from V$ performance views Cumulative data e.g. V$SYSSTAT Data based on deltas e.g. V$SQL Active Session History Metrics 9

AWR Basics Snapshots Process controlled by AWR metadata Settings visible in DBA_HIST_WR_CONTROL Metadata set using DBMS_WORKLOAD_REPOSITORY package Can also do manual snapshots 10

AWR Basics Snapshots Stores data in AWR tables in SYSAUX tablespace WRH$_xxx for data WRM$_xxx for metadata Access data directly using DBA_HIST_xxx views Large tables are partitioned for ease of management Especially for purge Partition size depends on retention No license requirement 11

AWR Basics Default configuration SQL> select * from dba_hist_wr_control; DBID SNAP_INTERVAL RETENTION TOPNSQL ---------- -------------------- -------------------- ---------- 4001518076 +00000 01:00:00.0 +00008 00:00:00.0 DEFAULT One hour default snapshot interval Eight day default retention Data automatically purged after retention period Default TOPNSQL is 200 for each dimension 12

AWR Basics Recommended configuration One hour or 30 minute snapshot interval If you think you need less, you are probably using the wrong data Attend Active Session History Deep Dive Moscone S Rm 104 Wed 15:30 Retention based on business cycles Default (8 days) is great for a play database on a laptop 30+ days for your important databases 60/90 days commonly used EXECUTE DBMS_WORKLOAD_REPOSITORY.MODIFY_SNAPSHOT_SETTINGS ( interval => 60, retention => 60*24*90); -- 90 days 13

AWR Reports How many AWR reports are there? awrrpt.sql 14

AWR Reports Use the report based on the scope of the problem How many AWR reports are there? awrrpt.sql Instance AWR report awrddrpt.sql Compare period report awrgrpt.sql RAC AWR report awrgdrpt.sql RAC Compare period report awrsqlrpt.sql AWR SQL history report ashrpt.sql ASH report addmrpt.sql ADDM report 15

AWR Report Beware! AWR averages data over the whole snapshot interval Can mislead investigations 16

AWR Report Beware! AWR averages data over the whole snapshot interval Can mislead investigations Event histograms help by allowing outliers to be identified 17

AWR Reports Analyzing the AWR report Scope the problem before starting to analyze the data AWR Report is very long But you are not expected to read it all Top few pages contains high level summary Summary leads you to where to look next 18

AWR Reports Analyzing the AWR report Look at the system overview unless you know the system well CPU cores Memory OS Oracle version RAC? Connected sessions Are any resources maxed out? 19

AWR Reports Analyzing the report If resource is maxed out, target that first DB CPU/sec => DB cores Paging/Swapping/High System time Otherwise focus on where DB Time is spent Top events Time model Top SQL 20

AWR Reports Analyzing the report Or use Tyler Muth s AWR Formatter for Chrome as a helper http://tylermuth.wordpress.com/2011/04/20/awr-formatter/ Or RUN THE ADDM REPORT 21

AWR Reports ADDM included in 12c AWR Findings at top of report Full ADDM report towards end of report 22

Real World Performance Issue 23

Recent Client Performance Issue REAL World Performance is messy Regular early morning intensive batch data load Loads two different data sets of around 500 million rows each into two new partitions Various aggregation and reporting steps at end of run One of the aggregation jobs had been running for over an hour rather than a few minutes and had been killed On a Saturday morning (of course) When my replacements were all out of signal range (of course) 24

Overall Approach Performance Analysis is Informed Common Sense Asking sensible questions How long does this usually run for? Few minutes When did it start running slowly? This morning Ran just fine every other day, including the previous day Start with the appropriate tools Use other tools for deeper analysis depending on the results 25

The right tool for the job AWR, ASH and ADDM are a suite of different tools Performance of a specific job has changed from one day to the next Overall system performance seems fine Probably a SQL statement or two has changed execution plan But let's not start guessing! SQL Monitor screen might show long-running statement No, because the problem happened some time ago ASH data (including DBA_HIST_ACTIVE_SESS_HISTORY) Shows a long-running SQL_ID in second period, but not why 26

Basic AWR report History of performance statistics The old way Run two AWR (or even Statspack) reports Print them off Sit at desk with them laid side-by-side Read through massive reports trying to spot the differences The better way AWR Compare Period Report 27

AWR Compare Period Report Summary Shows the database instance and version information Usually the same, but could be different databases and instances (more later) Shows the two periods we are comparing 28

AWR Compare Period Report Load Profile Similar to Load Profile section of basic report Shows both values side-by-side for immediate easy comparison Calculates percentage differences between two activity periods 29

AWR Compare Period Report Top Timed Events Where we are spending Time! Different events Different wait times Different contribution to DB Time Events that appear in one period and not the other 30

AWR Compare Period Report Top Timed Events 31

AWR Compare Period Report SQL by Elapsed Time Single job running more slowly than usual Check SQL statement Elapsed Time Changes Shows statements that appear in either or both of the snapshot intervals 32

AWR Compare Period Report SQL by Elapsed Time 33

AWR SQL Report Summary Run for a specific SQL_ID over a specific period of time Shows overall information for Elapsed Time and Application Instrumentation Shows that there are two different Execution Plans! 34

AWR SQL Report Summary 35

AWR SQL Report Plan Statistics All sections appear for all different plans Long Elapsed Time so this is the culprit Lots of User I/O Wait Time 36

AWR SQL Report Execution Plans This is the bad guy! Standard Execution Plan format CONNECT BY query that connects NODEs and EDGEs in a hierarchical tree 37

AWR SQL Report Execution Plans This is the usual plan! Same SQL statement operating against different partitions With different stats Uses a different CONNECT BY method that sorts to TEMP Quick fix solution Hint! 38

Colored SQL Even an AWR fan curses it sometimes! TOPNSQL defines how many statements AWR should capture Over multiple dimensions AWR doesn't (and probably shouldn't) capture (by default) Infrequently executed SQL statements that don't consume resources Which means that you often won't find the 'Good Guy' for comparison with the 'Bad Guy' dbms_workload_repository.add_colored_sql allows you to specify a SQL_ID that will always be captured if it is in the cursor cache 39

AWR is a suite of analysis tools But it's not the only tool Working our way through different tools Looking at different aspects of overall system and session performance Deciding which are the most important Wouldn t it be great if we had a tool that did that for us? 40

ADDM AWR Report use case What did ADDM say? Host CPU was the issue Latch issue ranked third 41

AWR Administration and Diagnostics It is self-managing! Drop and recreate AWR catnoawr.sql catawr.sql Extract and Load awrextr.sql awrload.sql 42

AWR Administration and Diagnostics Ah, Nuts Diagnose errors and performance issues "Troubleshooting: AWR Snapshot Collection issues (Doc ID 1301503.1) Identifying snapshot errors WRM$_SNAP_ERROR Not starting Not completing Tracing snapshots 43

AWR Administration and Diagnostics Ah, Nuts Diagnose errors and performance issues New in 11.2.0.2 WRM$_SNAPSHOT_DETAILS NAME TIME --------------------- ----------------------------- WRH$_STAT_NAME +000000000 00:00:00.238 WRH$_PARAMETER_NAME +000000000 00:00:03.159 WRH$_EVENT_NAME +000000000 00:00:00.476 WRH$_LATCH_NAME +000000000 00:00:00.296 WRH$_FILESTATXS +000000000 00:00:00.041 WRH$_TEMPSTATXS +000000000 00:00:00.011 WRH$_DATAFILE +000000000 00:00:00.018 44

AWR Soup to Nuts It IS More Than Just AWRRPT On by default and self-managing Basket of tools for investigating performance issue Scope of issue should lead to choice of tool Drill down based on DB Time Remember to ask ADDM 45

46

47

Slide Title: Arial, 28 PT Two-Line Max Subtitle: Arial, 20 pt, One-Line Max Bullets are sentence case. Use Arial, 20 pt font. Sub-bullets are Arial, 18 pt font. Keep bullets short. One idea per bullet. No more than five bullets. NOTE: Arial is the ONLY font that should be used in the Oracle corporate presentation template. Times and other serif fonts are not acceptable. To ensure that slides are properly formatted to this template, see pages 7 and for instructions. Arial Times 48

Slide Title: Arial, 28 PT Two-Line Max Subtitle: Arial, 20 pt, One-Line Max Bullets are sentence case. Use Arial, 20 pt font. Sub-bullets are Arial, 18 pt font. Keep bullets short. One idea per bullet. No more than five bullets. NOTE: Arial is the ONLY font that should be used in the Oracle corporate presentation template. Times and other serif fonts are not acceptable. To ensure that slides are properly formatted to this template, see pages 7 and for instructions. Arial Times 49

Slide Title: Arial, 28 PT, One-Line Subtitle: Arial, 20 pt, One-Line Max Bullets are sentence case. Use Arial, 20 pt font. Sub-bullets are Arial, 18 pt font. Keep bullets short. One idea per bullet. No more than five bullets. NOTE: Arial is the ONLY font that should be used in the Oracle corporate presentation template. Times and other serif fonts are not acceptable. To ensure that slides are properly formatted to this template, see pages 7 and for instructions. 50

Graphic Section Divider 51

Image Section Divider 52

ORACLE PRODUCT LOGO ANNOUNCEMENT ALL CAPS, ARIAL 44 PT, 4-LINE MAX Sample Image Go to slide 56 for link to download current hardware image collection 53

Title, Arial, 28 PT, Two-Line Max ORACLE PRODUCT LOGO BODY/STATEMENT COPY, ALL CAPS, 24 PT, HIGHLIGHT TEXT IN RED, USED FOR EMPHASIS 54

Case Study Example with Photograph Solutions Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce a sagittis orci. Maecenas vehicula lorem pharetra ipsum suscipit ut venenatis risus facilisis. Donec vel augue vitae urna aliquet cursus. Aliquam rutrum iaculis. 55

Case Study Example with Screenshot Solutions Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce a sagittis orci. Maecenas vehicula lorem pharetra ipsum suscipit ut venenatis risus facilisis. Donec vel augue vitae urna aliquet cursus. Aliquam rutrum iaculis. 56

Case Study Example with Graphic Solutions Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce a sagittis orci. Maecenas vehicula lorem pharetra ipsum suscipit ut venenatis risus facilisis. Donec vel augue vitae urna aliquet cursus. Aliquam rutrum iaculis. 57

Case Study Example with Partner Logos Solutions Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce a sagittis orci. Maecenas vehicula lorem pharetra ipsum suscipit ut venenatis risus facilisis. Donec vel augue vitae urna aliquet cursus. Aliquam rutrum iaculis. 58

THIRD PARTY COMPANY LOGO This slide format serves to call attention to a quote from a prominent customer, executive, or thought leader regarding a particular topic. Insert Author Name Here Position Title, Company Name 59

Vertical Bar Chart 6 5 Contextual information about the chart Bullet copy Bullet copy Bullet copy 4 3 2 1 0 Category 1 Category 2 Category 3 Category 4 Series 1 Series 2 Series 3 60

Horizontal Bar Chart Category 4 Contextual information about the chart Bullet copy Bullet copy Bullet copy Category 3 Category 2 Category 1 0 1 2 3 4 5 6 Series 3 Series 2 Series 1 61

Stacked Chart Contextual information about the chart Bullet copy Bullet copy Bullet copy 14 12 10 8 6 4 2 0 Category 1 Category 2 Category 3 Category 4 Series 1 Series 2 Series 3 62

Line Chart Contextual information about the chart Bullet copy Bullet copy Bullet copy 6 5 4 3 2 1 0 Category 1 Category 2 Category 3 Category 4 Series 1 Series 2 Series 3 63

Pie Chart Contextual information about the chart Bullet copy Bullet copy Bullet copy 4.5 3.5 4.3 2.5 Category 1 Category 2 Category 3 Category 4 64

Tables Title Bullet Bullet Sub-bullet Sub-bullet Sub-bullet Title Bullet Bullet Sub-bullet Sub-bullet Sub-bullet 65

Tables Title Bullet Bullet Sub-bullet Title Bullet Title Bullet 66

Tables Title Insert content here Insert content here Insert content here Insert content here Insert highlighted content here Insert content here Title Insert content here Insert content here Insert content here Insert content here Insert highlighted content here Insert content here 67

Tables Label Label Label Title Text Bullet Bullet Text Bullet Bullet Text Bullet Bullet Title Text Bullet Bullet Text Bullet Bullet Text Bullet Bullet 68

Tables Label Label Label Title Subtitle Text Bullet Bullet Text Bullet Bullet Text Bullet Bullet Title Subtitle Text Bullet Bullet Text Bullet Bullet Text Bullet Bullet 69

Tables Title Title Title Title Title Title Label Label Label Label 70

Tables Title Title Title Title Title Title Label 00.00 0.00 000.00 00.00 00.00 00.00 Label 0.00 00.00 0.00 0.00 0.00 0.00 Label 000.00 0.00 00.00 0.00 0.00 000.00 Label 0.00 000.00 0.00 000.00 00.00 00.00 71

72

73