SlideShare a Scribd company logo
1 of 42
Oracle Performance Tuning
Kyle Hailey
Kylelf@gmail.com
dboptimizer.com
Who is Kyle Hailey
ī‚§ 1990 Oracle
ī‚§ 90 support
ī‚§ 92 Ported v6
ī‚§ 93 France
ī‚§ 95 Benchmarking
ī‚§ 98 ST Real World Performance
ī‚§ 2000 Dot.Com
ī‚§ 2001 Quest
ī‚§ 2002 Oracle OEM 10g Success!Success!
First successful OEM designFirst successful OEM design
Who is Kyle Hailey
ī‚§ 1990 Oracle
ī‚§ 90 support
ī‚§ 92 Ported v6
ī‚§ 93 France
ī‚§ 95 Benchmarking
ī‚§ 98 ST Real World Performance
ī‚§ 2000 Dot.Com
ī‚§ 2001 Quest
ī‚§ 2002 Oracle OEM 10g
ī‚§ 2005 Embarcadero
ī‚§ DB Optimizer
Who is Kyle Hailey
ī‚§ 1990 Oracle
ī‚§ 90 support
ī‚§ 92 Ported v6
ī‚§ 93 France
ī‚§ 95 Benchmarking
ī‚§ 98 ST Real World Performance
ī‚§ 2000 Dot.Com
ī‚§ 2001 Quest
ī‚§ 2002 Oracle OEM 10g
ī‚§ 2005 Embarcadero
ī‚§ DB Optimizer
ī‚§ Delphix
When not being a Geek
- Have a little 4 year old boy who takes up all my time
Typical Architecture
DatabaseDatabase
File systemFile system
ProductionProduction
InstanceInstance
DatabaseDatabase
File systemFile system
DevelopmentDevelopment
InstanceInstance
DatabaseDatabase
File systemFile system
QAQA
InstanceInstance
DatabaseDatabase
UATUAT
InstanceInstance
File systemFile system
Database Virtualization
DevelopmentDevelopment
InstanceInstance
DatabaseDatabase
ProductionProduction
InstanceInstance
File systemFile system
vDatabasevDatabase
QAQA
InstanceInstance
UATUAT
InstanceInstance
vDatabasevDatabase vDatabasevDatabase
NFSNFS
SourceSource ClonesClones
FiberFiber
ChannelChannel
My Goal
Simplify the information
and empower the DBA
How do you tune a Database?
“Database is running slow!”
â€ĸWhat :
â€ĸ first step?
â€ĸ questions do you ask?
â€ĸ tools?
Do you have a repeatable method?
What statistics do you look at?
Launch: Pressure
Midnight
January 28, 1986
Lives are on the line
Thanks to Edward Tufte
13 Pages Faxed
Original Engineering data
only showed damage
““damages at the hottestdamages at the hottest
and coldest temperature”and coldest temperature”
-- managementmanagement
Congressional Hearings Evidence
Clearer
1. Include successes
2. Mark Differences
3. Normalize same temp
4. Scale known vs unknown
5555 6565 75756060 7070 8080
44
88
1212
44
88
1212
3030 4040 50503535 4545
XX
Difficult
ī‚§ NASA Engineers Fail
ī‚§ Congressional Investigators Fail
ī‚§ Data Visualization is Difficult
But â€Ļ
Lack of Clarity can be devastating
What statistics do you look at?
AASAAS
Solutions
â€ĸ Clear Identification
â€ĸ Know how to identify problems and issues
â€ĸ Access to details
â€ĸ Provide solutions and/or information to address the issues
â€ĸ Graphics
â€ĸ Easy understanding, effective communication and discussion
First Step: Graphics
“The humans â€Ļ are exceptionally good
at parsing visual information,
especially when that information is
coded by color and/or .”
Knowledge representation in cognitive science. Westbury, C. & Wilensky, U. (1998)
motionmotion
Why Use Graphics
   You can't imagine how many times I was told that nobody wanted or
would use graphics â€Ļ
-- Jef Raskin, the creator of the Macintosh
Infocus – (overhead projectors) sited a
study that humans can parse graphical
information 400,000 times faster than
textual data
Counties in US
ī‚§ 3101 Counties
ī‚§ 50 pages
“If I can't picture it, I can't understand it”
Anscombe's Quartet
I II III IV
x y x y x y x y
10 8.04 10 9.14 10 7.46 8 6.58
8 6.95 8 8.14 8 6.77 8 5.76
13 7.58 13 8.74 13 12.74 8 7.71
9 8.81 9 8.77 9 7.11 8 8.84
11 8.33 11 9.26 11 7.81 8 8.47
14 9.96 14 8.1 14 8.84 8 7.04
6 7.24 6 6.13 6 6.08 8 5.25
4 4.26 4 3.1 4 5.39 19 12.5
12 10.84 12 9.13 12 8.15 8 5.56
7 4.82 7 7.26 7 6.42 8 7.91
5 5.68 5 4.74 5 5.73 8 6.89
Average 9 7.5 9 7.5 9 7.5 9 7.5
Standard Deviation 3.31 2.03 3.31 2.03 3.31 2.03 3.31 2.03
Linear Regression 1.33 1.33 1.33 1.33
- Albert Einstein- Albert Einstein
Graphics for Anscombe’s Quartet
What is a day in the life look likeWhat is a day in the life look like
for a DBA who has performancefor a DBA who has performance
issues?issues?
Tuning the Database
Anscombe's Quartet
I II III IV
x y x y x y x y
Average 9 7.5 9 7.5 9 7.5 9 7.5
Standard Deviation 3.31 2.03 3.31 2.03 3.31 2.03 3.31 2.03
Linear Regression 1.33 1.33 1.33 1.33
ComplexComplex
AveragesAverages
LOADLOAD
TopTop
ActivityActivity
SQLSQL EventsEvents SessionsSessions
Max CPUMax CPU
(yard stick)(yard stick)
How Can We Open the Black Box?
LOADLOAD
TopTop
ActivityActivity
SQLSQL EventsEvents SessionsSessions
Get DetailsGet Details
Click hereClick here
Max CPUMax CPU
(yard stick)(yard stick)
How Can We Open the Black Box?
How Can We Open the Black Box?
OEMOEM ASHMON/SASHASHMON/SASH DB OptimizerDB Optimizer
â€ĸPowerful - Identifies issues quickly and powerfully
â€ĸInteractive - Allows exploring the data
â€ĸEasy - Understandable by everyone, DBA, Dev and Managers !
Ideas for Today
ASHASH
SamplingSampling
WaitsWaits
AASAAS
Before Tuning Oracle, Tune the Machine
Make sure the machine is healthy before tuning Oracle
ī‚§ CPU => use run queue, < 2 * #CPU
ī‚§ Memory => page out
VMSTAT
Sections
ī‚§ Statspack
ī‚§ ASH
ī‚§ AAS
ī‚§ OEM 10g
ī‚§ Buffer Cache
ī‚§ IO
ī‚§ Redo
ī‚§ Enqueues
ī‚§ Shared Pool
ī‚§ SQL*Net
ī‚§ SQL Tuning
Do You Want?
Engineering Data?Engineering Data?
Do You Want?
Pretty PicturesPretty Pictures
Do You Want?
Clean and ClearClean and Clear
? ? ? ?? ? ? ?
? ?? ?
Imagine Trying to Drive your Car
And is updated once and hourAnd is updated once and hour
Or would you like it toOr would you like it to
look â€Ļlook â€Ļ
Would you want your dashboard to look like :Would you want your dashboard to look like :
Or This
Embarcadero
35
Summary
1.Machine - vmstat
ī‚§ Memory, CPU (we can see IO response in Oracle)
1.Database - AAS
ī‚§ Use wait interface and graphics
ī‚§ Identify machine, application, database or SQL
1.SQL - VST
ī‚§ Indexes, stats, execution path
ī‚§ Visual SQL Tuning
Bibliography
www.simple-talk.com/sql/performance/designing-efficient-sql-a-visual-approach/www.simple-talk.com/sql/performance/designing-efficient-sql-a-visual-approach/
Refactoring SQL Applications – Stephane Faroult
Troubleshooting Oracle Performance – Christian Antognini
SQL Tuning – Dan Tow
Cost-Based Oracle Fundamentals – Jonathan Lewis
Books
ī‚§ The Visual Display of
Quantitative Information
ī‚§ Eduard Tufte
ī‚§ Oracle Wait Interface
ī‚§ Kirtikumar Deshpande, K. Gopalakrishnan
ī‚§ SQL Tuning
ī‚§ Dan Tow
DesignDesign
WaitsWaits
SQLSQL
Books
ī‚§ Jonathan Lewis
ī‚§ Cost-Based Oracle (Tough Read)
ī‚§ Practical Oracle 8i (easy read)
ī‚§ Oracle Insights
ī‚§ Kyle Hailey & Oaktable Members
DirectDirect
MemoryMemory
AttachAttach
OracleOracle
OptimizerOptimizer
END
Copyright 2006Copyright 2006
When to Tune
1. Machine
a) CPU
ī‚§ Response times skewed
ī‚§ 100% CPU might be fine
ī‚§ Users wait in queue (run queue) => machine
underpowered
a) Memory
ī‚§ Paging
ī‚§ Wait times skewed (ex : latch free)
ī‚§ Erratic response times ( ex : ls )
1. Oracle
1) Waits > CPU ?
ī‚§ tune waits
1) CPU > 100% ?
ī‚§ tune top CPU SQL
1) Else
ī‚§ It’s the application
Oracle LoadOracle Load
(AAS)(AAS)
Top SessionTop Session Top WaitTop Wait Top SQLTop SQL
SQL DetailSQL Detail Session DetailSession Detail File DetailFile DetailObject DetailObject Detail Wait DetailWait Detail
HostHost
AAS >AAS >
#CPU#CPU
AAS > 1AAS > 1
Waits >Waits >
CPUCPU
CPU >CPU >
WaitsWaits
CPUCPU
MemoryMemory
Summary
1.Database - AAS
ī‚§ Profile database
ī‚§ Use wait interface and graphics
ī‚§ Identify machine, application, database or SQL
1.SQL - VST
ī‚§ Indexes, stats, execution path
ī‚§ Visual SQL Tuning

More Related Content

What's hot

Dba 3+ exp qus
Dba 3+ exp qusDba 3+ exp qus
Dba 3+ exp qus
krreddy21
 
Parallel Query on Exadata
Parallel Query on ExadataParallel Query on Exadata
Parallel Query on Exadata
Enkitec
 
Tuning SQL for Oracle Exadata: The Good, The Bad, and The Ugly Tuning SQL fo...
 Tuning SQL for Oracle Exadata: The Good, The Bad, and The Ugly Tuning SQL fo... Tuning SQL for Oracle Exadata: The Good, The Bad, and The Ugly Tuning SQL fo...
Tuning SQL for Oracle Exadata: The Good, The Bad, and The Ugly Tuning SQL fo...
Enkitec
 
Oracle dba interview questions with answer
Oracle dba interview questions with answerOracle dba interview questions with answer
Oracle dba interview questions with answer
upenpriti
 
Performance Tuning With Oracle ASH and AWR. Part 1 How And What
Performance Tuning With Oracle ASH and AWR. Part 1 How And WhatPerformance Tuning With Oracle ASH and AWR. Part 1 How And What
Performance Tuning With Oracle ASH and AWR. Part 1 How And What
udaymoogala
 
Oracle performance tuning_sfsf
Oracle performance tuning_sfsfOracle performance tuning_sfsf
Oracle performance tuning_sfsf
Mao Geng
 

What's hot (20)

Using Statspack and AWR for Memory Monitoring and Tuning
Using Statspack and AWR for Memory Monitoring and TuningUsing Statspack and AWR for Memory Monitoring and Tuning
Using Statspack and AWR for Memory Monitoring and Tuning
 
Create your oracle_apps_r12_lab_with_less_than_us1000
Create your oracle_apps_r12_lab_with_less_than_us1000Create your oracle_apps_r12_lab_with_less_than_us1000
Create your oracle_apps_r12_lab_with_less_than_us1000
 
Ash and awr deep dive hotsos
Ash and awr deep dive hotsosAsh and awr deep dive hotsos
Ash and awr deep dive hotsos
 
Oracle AWR Data mining
Oracle AWR Data miningOracle AWR Data mining
Oracle AWR Data mining
 
Dba 3+ exp qus
Dba 3+ exp qusDba 3+ exp qus
Dba 3+ exp qus
 
Your tuning arsenal: AWR, ADDM, ASH, Metrics and Advisors
Your tuning arsenal: AWR, ADDM, ASH, Metrics and AdvisorsYour tuning arsenal: AWR, ADDM, ASH, Metrics and Advisors
Your tuning arsenal: AWR, ADDM, ASH, Metrics and Advisors
 
Parallel Query on Exadata
Parallel Query on ExadataParallel Query on Exadata
Parallel Query on Exadata
 
Best practices for_large_oracle_apps_r12_implementations
Best practices for_large_oracle_apps_r12_implementationsBest practices for_large_oracle_apps_r12_implementations
Best practices for_large_oracle_apps_r12_implementations
 
Tuning SQL for Oracle Exadata: The Good, The Bad, and The Ugly Tuning SQL fo...
 Tuning SQL for Oracle Exadata: The Good, The Bad, and The Ugly Tuning SQL fo... Tuning SQL for Oracle Exadata: The Good, The Bad, and The Ugly Tuning SQL fo...
Tuning SQL for Oracle Exadata: The Good, The Bad, and The Ugly Tuning SQL fo...
 
Using AWR for SQL Analysis
Using AWR for SQL AnalysisUsing AWR for SQL Analysis
Using AWR for SQL Analysis
 
Why is my_oracle_e-biz_database_slow_a_million_dollar_question
Why is my_oracle_e-biz_database_slow_a_million_dollar_questionWhy is my_oracle_e-biz_database_slow_a_million_dollar_question
Why is my_oracle_e-biz_database_slow_a_million_dollar_question
 
Crack the complexity of oracle applications r12 workload v2
Crack the complexity of oracle applications r12 workload v2Crack the complexity of oracle applications r12 workload v2
Crack the complexity of oracle applications r12 workload v2
 
Oracle Exadata 1Z0-485 Certification
Oracle Exadata 1Z0-485 CertificationOracle Exadata 1Z0-485 Certification
Oracle Exadata 1Z0-485 Certification
 
Sql Performance Tuning with ASH &amp; AWR: Real World Use Cases
Sql Performance Tuning with ASH &amp; AWR: Real World Use CasesSql Performance Tuning with ASH &amp; AWR: Real World Use Cases
Sql Performance Tuning with ASH &amp; AWR: Real World Use Cases
 
Oracle Exadata X2-8: A Critical Review
Oracle Exadata X2-8: A Critical ReviewOracle Exadata X2-8: A Critical Review
Oracle Exadata X2-8: A Critical Review
 
Oracle dba interview questions with answer
Oracle dba interview questions with answerOracle dba interview questions with answer
Oracle dba interview questions with answer
 
DevSecOps PLM L2 Playbook.pdf
DevSecOps PLM L2 Playbook.pdfDevSecOps PLM L2 Playbook.pdf
DevSecOps PLM L2 Playbook.pdf
 
Performance Tuning With Oracle ASH and AWR. Part 1 How And What
Performance Tuning With Oracle ASH and AWR. Part 1 How And WhatPerformance Tuning With Oracle ASH and AWR. Part 1 How And What
Performance Tuning With Oracle ASH and AWR. Part 1 How And What
 
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR uses
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR usesEarl Shaffer Oracle Performance Tuning pre12c 11g AWR uses
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR uses
 
Oracle performance tuning_sfsf
Oracle performance tuning_sfsfOracle performance tuning_sfsf
Oracle performance tuning_sfsf
 

Viewers also liked

Oracle database performance tuning
Oracle database performance tuningOracle database performance tuning
Oracle database performance tuning
Yogiji Creations
 
Oracle 12c RAC On your laptop Step by Step Implementation Guide 1.0
Oracle 12c RAC On your laptop Step by Step Implementation Guide 1.0Oracle 12c RAC On your laptop Step by Step Implementation Guide 1.0
Oracle 12c RAC On your laptop Step by Step Implementation Guide 1.0
Yury Velikanov
 
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Aaron Shilo
 
Oracle 10g Performance: chapter 00 statspack
Oracle 10g Performance: chapter 00 statspackOracle 10g Performance: chapter 00 statspack
Oracle 10g Performance: chapter 00 statspack
Kyle Hailey
 
Oracle 10g Performance: chapter 01 ash
Oracle 10g Performance: chapter 01 ashOracle 10g Performance: chapter 01 ash
Oracle 10g Performance: chapter 01 ash
Kyle Hailey
 
Oracle 10g rac_overview
Oracle 10g rac_overviewOracle 10g rac_overview
Oracle 10g rac_overview
Robel Parvini
 
Oracle db performance tuning
Oracle db performance tuningOracle db performance tuning
Oracle db performance tuning
Simon Huang
 

Viewers also liked (20)

Oracle DB Performance Tuning Tips
Oracle DB Performance Tuning TipsOracle DB Performance Tuning Tips
Oracle DB Performance Tuning Tips
 
Step By Step Install Oracle 10g Rac Asm On Windows
Step By Step Install Oracle 10g Rac Asm On WindowsStep By Step Install Oracle 10g Rac Asm On Windows
Step By Step Install Oracle 10g Rac Asm On Windows
 
Oracle database performance tuning
Oracle database performance tuningOracle database performance tuning
Oracle database performance tuning
 
Oracle 12c RAC On your laptop Step by Step Implementation Guide 1.0
Oracle 12c RAC On your laptop Step by Step Implementation Guide 1.0Oracle 12c RAC On your laptop Step by Step Implementation Guide 1.0
Oracle 12c RAC On your laptop Step by Step Implementation Guide 1.0
 
Top 10 tips for Oracle performance (Updated April 2015)
Top 10 tips for Oracle performance (Updated April 2015)Top 10 tips for Oracle performance (Updated April 2015)
Top 10 tips for Oracle performance (Updated April 2015)
 
Oracle sql high performance tuning
Oracle sql high performance tuningOracle sql high performance tuning
Oracle sql high performance tuning
 
zero data loss recovery appliance
 zero data loss recovery appliance zero data loss recovery appliance
zero data loss recovery appliance
 
Database As A Service: OEM + ODA (OOW 15 Presentation)
Database As A Service: OEM + ODA (OOW 15 Presentation)Database As A Service: OEM + ODA (OOW 15 Presentation)
Database As A Service: OEM + ODA (OOW 15 Presentation)
 
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
 
Oracle cloud, private, public and hybrid
Oracle cloud, private, public and hybridOracle cloud, private, public and hybrid
Oracle cloud, private, public and hybrid
 
Oracle 10g Performance: chapter 00 statspack
Oracle 10g Performance: chapter 00 statspackOracle 10g Performance: chapter 00 statspack
Oracle 10g Performance: chapter 00 statspack
 
SQL Tuning and VST
SQL Tuning and VST SQL Tuning and VST
SQL Tuning and VST
 
Oracle 10g Performance: chapter 01 ash
Oracle 10g Performance: chapter 01 ashOracle 10g Performance: chapter 01 ash
Oracle 10g Performance: chapter 01 ash
 
Message Queue (MQ) Testing
Message Queue (MQ) TestingMessage Queue (MQ) Testing
Message Queue (MQ) Testing
 
Oracle Performance Tuning Fundamentals
Oracle Performance Tuning FundamentalsOracle Performance Tuning Fundamentals
Oracle Performance Tuning Fundamentals
 
Oracle 10g rac_overview
Oracle 10g rac_overviewOracle 10g rac_overview
Oracle 10g rac_overview
 
Oracle LOB Internals and Performance Tuning
Oracle LOB Internals and Performance TuningOracle LOB Internals and Performance Tuning
Oracle LOB Internals and Performance Tuning
 
Creating Queue Manager and Queue's in IBM WebSphere Mq
Creating Queue Manager and Queue's in IBM WebSphere MqCreating Queue Manager and Queue's in IBM WebSphere Mq
Creating Queue Manager and Queue's in IBM WebSphere Mq
 
Oracle db performance tuning
Oracle db performance tuningOracle db performance tuning
Oracle db performance tuning
 
Sending and receiving messages in mq queues
Sending and receiving messages in mq queuesSending and receiving messages in mq queues
Sending and receiving messages in mq queues
 

Similar to Oracle 10g Performance: chapter 00 intro live_short

dokumen.tips_oracle-10g-advanced-performance-tuning-kyle-hailey-kylelfgmailco...
dokumen.tips_oracle-10g-advanced-performance-tuning-kyle-hailey-kylelfgmailco...dokumen.tips_oracle-10g-advanced-performance-tuning-kyle-hailey-kylelfgmailco...
dokumen.tips_oracle-10g-advanced-performance-tuning-kyle-hailey-kylelfgmailco...
cookie1969
 
Advanced Analytics and Recommendations with Apache Spark - Spark Maryland/DC ...
Advanced Analytics and Recommendations with Apache Spark - Spark Maryland/DC ...Advanced Analytics and Recommendations with Apache Spark - Spark Maryland/DC ...
Advanced Analytics and Recommendations with Apache Spark - Spark Maryland/DC ...
Chris Fregly
 
Parallelism Processor Design
Parallelism Processor DesignParallelism Processor Design
Parallelism Processor Design
Sri Prasanna
 

Similar to Oracle 10g Performance: chapter 00 intro live_short (20)

dokumen.tips_oracle-10g-advanced-performance-tuning-kyle-hailey-kylelfgmailco...
dokumen.tips_oracle-10g-advanced-performance-tuning-kyle-hailey-kylelfgmailco...dokumen.tips_oracle-10g-advanced-performance-tuning-kyle-hailey-kylelfgmailco...
dokumen.tips_oracle-10g-advanced-performance-tuning-kyle-hailey-kylelfgmailco...
 
Comparison between rdbms and nosql
Comparison between rdbms and nosqlComparison between rdbms and nosql
Comparison between rdbms and nosql
 
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI ProjectsDiscovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
 
SQL on Hadoop benchmarks using TPC-DS query set
SQL on Hadoop benchmarks using TPC-DS query setSQL on Hadoop benchmarks using TPC-DS query set
SQL on Hadoop benchmarks using TPC-DS query set
 
Tech
TechTech
Tech
 
Building a cutting-edge data processing environment on a budget
Building a cutting-edge data processing environment on a budgetBuilding a cutting-edge data processing environment on a budget
Building a cutting-edge data processing environment on a budget
 
SQLCAT: Tier-1 BI in the World of Big Data
SQLCAT: Tier-1 BI in the World of Big DataSQLCAT: Tier-1 BI in the World of Big Data
SQLCAT: Tier-1 BI in the World of Big Data
 
"Wix Engineering Media AI Photo Studio", Mykola Mykhailych
"Wix Engineering Media AI Photo Studio", Mykola Mykhailych"Wix Engineering Media AI Photo Studio", Mykola Mykhailych
"Wix Engineering Media AI Photo Studio", Mykola Mykhailych
 
Computer architecture
Computer architectureComputer architecture
Computer architecture
 
DUDE AT SAOUG 2008
DUDE AT SAOUG 2008DUDE AT SAOUG 2008
DUDE AT SAOUG 2008
 
Spark, Similarity, Approximations, NLP, Recommendations - Boulder Denver Spar...
Spark, Similarity, Approximations, NLP, Recommendations - Boulder Denver Spar...Spark, Similarity, Approximations, NLP, Recommendations - Boulder Denver Spar...
Spark, Similarity, Approximations, NLP, Recommendations - Boulder Denver Spar...
 
XMLDB Building Blocks And Best Practices - Oracle Open World 2008 - Marco Gra...
XMLDB Building Blocks And Best Practices - Oracle Open World 2008 - Marco Gra...XMLDB Building Blocks And Best Practices - Oracle Open World 2008 - Marco Gra...
XMLDB Building Blocks And Best Practices - Oracle Open World 2008 - Marco Gra...
 
Building a Cutting-Edge Data Process Environment on a Budget by Gael Varoquaux
Building a Cutting-Edge Data Process Environment on a Budget by Gael VaroquauxBuilding a Cutting-Edge Data Process Environment on a Budget by Gael Varoquaux
Building a Cutting-Edge Data Process Environment on a Budget by Gael Varoquaux
 
Introduction to Deep Learning
Introduction to Deep LearningIntroduction to Deep Learning
Introduction to Deep Learning
 
Solr and Machine Vision - Scott Cote, Lucidworks & Trevor Grant, IBM
Solr and Machine Vision - Scott Cote, Lucidworks & Trevor Grant, IBMSolr and Machine Vision - Scott Cote, Lucidworks & Trevor Grant, IBM
Solr and Machine Vision - Scott Cote, Lucidworks & Trevor Grant, IBM
 
Advanced Analytics and Recommendations with Apache Spark - Spark Maryland/DC ...
Advanced Analytics and Recommendations with Apache Spark - Spark Maryland/DC ...Advanced Analytics and Recommendations with Apache Spark - Spark Maryland/DC ...
Advanced Analytics and Recommendations with Apache Spark - Spark Maryland/DC ...
 
5th Athens Big Data Meetup - PipelineIO Workshop - Real-Time Training and Dep...
5th Athens Big Data Meetup - PipelineIO Workshop - Real-Time Training and Dep...5th Athens Big Data Meetup - PipelineIO Workshop - Real-Time Training and Dep...
5th Athens Big Data Meetup - PipelineIO Workshop - Real-Time Training and Dep...
 
Interview
InterviewInterview
Interview
 
Data Mining with Excel 2010 and PowerPivot 201106
Data Mining with Excel 2010 and PowerPivot 201106Data Mining with Excel 2010 and PowerPivot 201106
Data Mining with Excel 2010 and PowerPivot 201106
 
Parallelism Processor Design
Parallelism Processor DesignParallelism Processor Design
Parallelism Processor Design
 

More from Kyle Hailey

Data Virtualization: Revolutionizing data cloning
Data Virtualization: Revolutionizing data cloningData Virtualization: Revolutionizing data cloning
Data Virtualization: Revolutionizing data cloning
Kyle Hailey
 
Oracle Open World 2014: Lies, Damned Lies, and I/O Statistics [ CON3671]
Oracle Open World 2014: Lies, Damned Lies, and I/O Statistics [ CON3671]Oracle Open World 2014: Lies, Damned Lies, and I/O Statistics [ CON3671]
Oracle Open World 2014: Lies, Damned Lies, and I/O Statistics [ CON3671]
Kyle Hailey
 

More from Kyle Hailey (20)

Hooks in postgresql by Guillaume Lelarge
Hooks in postgresql by Guillaume LelargeHooks in postgresql by Guillaume Lelarge
Hooks in postgresql by Guillaume Lelarge
 
Performance insights twitch
Performance insights twitchPerformance insights twitch
Performance insights twitch
 
History of database monitoring
History of database monitoringHistory of database monitoring
History of database monitoring
 
Ash masters : advanced ash analytics on Oracle
Ash masters : advanced ash analytics on Oracle Ash masters : advanced ash analytics on Oracle
Ash masters : advanced ash analytics on Oracle
 
Successfully convince people with data visualization
Successfully convince people with data visualizationSuccessfully convince people with data visualization
Successfully convince people with data visualization
 
Virtual Data : Eliminating the data constraint in Application Development
Virtual Data :  Eliminating the data constraint in Application DevelopmentVirtual Data :  Eliminating the data constraint in Application Development
Virtual Data : Eliminating the data constraint in Application Development
 
DBTA Data Summit : Eliminating the data constraint in Application Development
DBTA Data Summit : Eliminating the data constraint in Application DevelopmentDBTA Data Summit : Eliminating the data constraint in Application Development
DBTA Data Summit : Eliminating the data constraint in Application Development
 
Accelerate Develoment with VIrtual Data
Accelerate Develoment with VIrtual DataAccelerate Develoment with VIrtual Data
Accelerate Develoment with VIrtual Data
 
Delphix and Pure Storage partner
Delphix and Pure Storage partnerDelphix and Pure Storage partner
Delphix and Pure Storage partner
 
Mark Farnam : Minimizing the Concurrency Footprint of Transactions
Mark Farnam  : Minimizing the Concurrency Footprint of TransactionsMark Farnam  : Minimizing the Concurrency Footprint of Transactions
Mark Farnam : Minimizing the Concurrency Footprint of Transactions
 
Dan Norris: Exadata security
Dan Norris: Exadata securityDan Norris: Exadata security
Dan Norris: Exadata security
 
Martin Klier : Volkswagen for Oracle Guys
Martin Klier : Volkswagen for Oracle GuysMartin Klier : Volkswagen for Oracle Guys
Martin Klier : Volkswagen for Oracle Guys
 
What is DevOps
What is DevOpsWhat is DevOps
What is DevOps
 
Data as a Service
Data as a Service Data as a Service
Data as a Service
 
Data Virtualization: Revolutionizing data cloning
Data Virtualization: Revolutionizing data cloningData Virtualization: Revolutionizing data cloning
Data Virtualization: Revolutionizing data cloning
 
BGOUG "Agile Data: revolutionizing database cloning'
BGOUG  "Agile Data: revolutionizing database cloning'BGOUG  "Agile Data: revolutionizing database cloning'
BGOUG "Agile Data: revolutionizing database cloning'
 
Denver devops : enabling DevOps with data virtualization
Denver devops : enabling DevOps with data virtualizationDenver devops : enabling DevOps with data virtualization
Denver devops : enabling DevOps with data virtualization
 
Oracle Open World 2014: Lies, Damned Lies, and I/O Statistics [ CON3671]
Oracle Open World 2014: Lies, Damned Lies, and I/O Statistics [ CON3671]Oracle Open World 2014: Lies, Damned Lies, and I/O Statistics [ CON3671]
Oracle Open World 2014: Lies, Damned Lies, and I/O Statistics [ CON3671]
 
Jonathan Lewis explains Delphix
Jonathan Lewis explains Delphix Jonathan Lewis explains Delphix
Jonathan Lewis explains Delphix
 
Oaktable World 2014 Toon Koppelaars: database constraints polite excuse
Oaktable World 2014 Toon Koppelaars: database constraints polite excuseOaktable World 2014 Toon Koppelaars: database constraints polite excuse
Oaktable World 2014 Toon Koppelaars: database constraints polite excuse
 

Recently uploaded

Recently uploaded (20)

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
đŸŦ The future of MySQL is Postgres 🐘
đŸŦ  The future of MySQL is Postgres   🐘đŸŦ  The future of MySQL is Postgres   🐘
đŸŦ The future of MySQL is Postgres 🐘
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 

Oracle 10g Performance: chapter 00 intro live_short

  • 1. Oracle Performance Tuning Kyle Hailey Kylelf@gmail.com dboptimizer.com
  • 2. Who is Kyle Hailey ī‚§ 1990 Oracle ī‚§ 90 support ī‚§ 92 Ported v6 ī‚§ 93 France ī‚§ 95 Benchmarking ī‚§ 98 ST Real World Performance ī‚§ 2000 Dot.Com ī‚§ 2001 Quest ī‚§ 2002 Oracle OEM 10g Success!Success! First successful OEM designFirst successful OEM design
  • 3. Who is Kyle Hailey ī‚§ 1990 Oracle ī‚§ 90 support ī‚§ 92 Ported v6 ī‚§ 93 France ī‚§ 95 Benchmarking ī‚§ 98 ST Real World Performance ī‚§ 2000 Dot.Com ī‚§ 2001 Quest ī‚§ 2002 Oracle OEM 10g ī‚§ 2005 Embarcadero ī‚§ DB Optimizer
  • 4. Who is Kyle Hailey ī‚§ 1990 Oracle ī‚§ 90 support ī‚§ 92 Ported v6 ī‚§ 93 France ī‚§ 95 Benchmarking ī‚§ 98 ST Real World Performance ī‚§ 2000 Dot.Com ī‚§ 2001 Quest ī‚§ 2002 Oracle OEM 10g ī‚§ 2005 Embarcadero ī‚§ DB Optimizer ī‚§ Delphix When not being a Geek - Have a little 4 year old boy who takes up all my time
  • 5. Typical Architecture DatabaseDatabase File systemFile system ProductionProduction InstanceInstance DatabaseDatabase File systemFile system DevelopmentDevelopment InstanceInstance DatabaseDatabase File systemFile system QAQA InstanceInstance DatabaseDatabase UATUAT InstanceInstance File systemFile system
  • 6. Database Virtualization DevelopmentDevelopment InstanceInstance DatabaseDatabase ProductionProduction InstanceInstance File systemFile system vDatabasevDatabase QAQA InstanceInstance UATUAT InstanceInstance vDatabasevDatabase vDatabasevDatabase NFSNFS SourceSource ClonesClones FiberFiber ChannelChannel
  • 7. My Goal Simplify the information and empower the DBA
  • 8. How do you tune a Database? “Database is running slow!” â€ĸWhat : â€ĸ first step? â€ĸ questions do you ask? â€ĸ tools? Do you have a repeatable method?
  • 9. What statistics do you look at?
  • 10. Launch: Pressure Midnight January 28, 1986 Lives are on the line Thanks to Edward Tufte
  • 12. Original Engineering data only showed damage ““damages at the hottestdamages at the hottest and coldest temperature”and coldest temperature” -- managementmanagement
  • 14. Clearer 1. Include successes 2. Mark Differences 3. Normalize same temp 4. Scale known vs unknown 5555 6565 75756060 7070 8080 44 88 1212 44 88 1212 3030 4040 50503535 4545 XX
  • 15. Difficult ī‚§ NASA Engineers Fail ī‚§ Congressional Investigators Fail ī‚§ Data Visualization is Difficult But â€Ļ Lack of Clarity can be devastating
  • 16. What statistics do you look at? AASAAS
  • 17. Solutions â€ĸ Clear Identification â€ĸ Know how to identify problems and issues â€ĸ Access to details â€ĸ Provide solutions and/or information to address the issues â€ĸ Graphics â€ĸ Easy understanding, effective communication and discussion
  • 18. First Step: Graphics “The humans â€Ļ are exceptionally good at parsing visual information, especially when that information is coded by color and/or .” Knowledge representation in cognitive science. Westbury, C. & Wilensky, U. (1998) motionmotion
  • 19. Why Use Graphics    You can't imagine how many times I was told that nobody wanted or would use graphics â€Ļ -- Jef Raskin, the creator of the Macintosh Infocus – (overhead projectors) sited a study that humans can parse graphical information 400,000 times faster than textual data
  • 20. Counties in US ī‚§ 3101 Counties ī‚§ 50 pages
  • 21. “If I can't picture it, I can't understand it” Anscombe's Quartet I II III IV x y x y x y x y 10 8.04 10 9.14 10 7.46 8 6.58 8 6.95 8 8.14 8 6.77 8 5.76 13 7.58 13 8.74 13 12.74 8 7.71 9 8.81 9 8.77 9 7.11 8 8.84 11 8.33 11 9.26 11 7.81 8 8.47 14 9.96 14 8.1 14 8.84 8 7.04 6 7.24 6 6.13 6 6.08 8 5.25 4 4.26 4 3.1 4 5.39 19 12.5 12 10.84 12 9.13 12 8.15 8 5.56 7 4.82 7 7.26 7 6.42 8 7.91 5 5.68 5 4.74 5 5.73 8 6.89 Average 9 7.5 9 7.5 9 7.5 9 7.5 Standard Deviation 3.31 2.03 3.31 2.03 3.31 2.03 3.31 2.03 Linear Regression 1.33 1.33 1.33 1.33 - Albert Einstein- Albert Einstein
  • 23. What is a day in the life look likeWhat is a day in the life look like for a DBA who has performancefor a DBA who has performance issues?issues? Tuning the Database Anscombe's Quartet I II III IV x y x y x y x y Average 9 7.5 9 7.5 9 7.5 9 7.5 Standard Deviation 3.31 2.03 3.31 2.03 3.31 2.03 3.31 2.03 Linear Regression 1.33 1.33 1.33 1.33 ComplexComplex AveragesAverages
  • 24. LOADLOAD TopTop ActivityActivity SQLSQL EventsEvents SessionsSessions Max CPUMax CPU (yard stick)(yard stick) How Can We Open the Black Box?
  • 25. LOADLOAD TopTop ActivityActivity SQLSQL EventsEvents SessionsSessions Get DetailsGet Details Click hereClick here Max CPUMax CPU (yard stick)(yard stick) How Can We Open the Black Box?
  • 26. How Can We Open the Black Box? OEMOEM ASHMON/SASHASHMON/SASH DB OptimizerDB Optimizer â€ĸPowerful - Identifies issues quickly and powerfully â€ĸInteractive - Allows exploring the data â€ĸEasy - Understandable by everyone, DBA, Dev and Managers !
  • 28. Before Tuning Oracle, Tune the Machine Make sure the machine is healthy before tuning Oracle ī‚§ CPU => use run queue, < 2 * #CPU ī‚§ Memory => page out VMSTAT
  • 29. Sections ī‚§ Statspack ī‚§ ASH ī‚§ AAS ī‚§ OEM 10g ī‚§ Buffer Cache ī‚§ IO ī‚§ Redo ī‚§ Enqueues ī‚§ Shared Pool ī‚§ SQL*Net ī‚§ SQL Tuning
  • 30. Do You Want? Engineering Data?Engineering Data?
  • 31. Do You Want? Pretty PicturesPretty Pictures
  • 32. Do You Want? Clean and ClearClean and Clear ? ? ? ?? ? ? ? ? ?? ?
  • 33. Imagine Trying to Drive your Car And is updated once and hourAnd is updated once and hour Or would you like it toOr would you like it to look â€Ļlook â€Ļ Would you want your dashboard to look like :Would you want your dashboard to look like :
  • 36. Summary 1.Machine - vmstat ī‚§ Memory, CPU (we can see IO response in Oracle) 1.Database - AAS ī‚§ Use wait interface and graphics ī‚§ Identify machine, application, database or SQL 1.SQL - VST ī‚§ Indexes, stats, execution path ī‚§ Visual SQL Tuning
  • 37. Bibliography www.simple-talk.com/sql/performance/designing-efficient-sql-a-visual-approach/www.simple-talk.com/sql/performance/designing-efficient-sql-a-visual-approach/ Refactoring SQL Applications – Stephane Faroult Troubleshooting Oracle Performance – Christian Antognini SQL Tuning – Dan Tow Cost-Based Oracle Fundamentals – Jonathan Lewis
  • 38. Books ī‚§ The Visual Display of Quantitative Information ī‚§ Eduard Tufte ī‚§ Oracle Wait Interface ī‚§ Kirtikumar Deshpande, K. Gopalakrishnan ī‚§ SQL Tuning ī‚§ Dan Tow DesignDesign WaitsWaits SQLSQL
  • 39. Books ī‚§ Jonathan Lewis ī‚§ Cost-Based Oracle (Tough Read) ī‚§ Practical Oracle 8i (easy read) ī‚§ Oracle Insights ī‚§ Kyle Hailey & Oaktable Members DirectDirect MemoryMemory AttachAttach OracleOracle OptimizerOptimizer
  • 41. When to Tune 1. Machine a) CPU ī‚§ Response times skewed ī‚§ 100% CPU might be fine ī‚§ Users wait in queue (run queue) => machine underpowered a) Memory ī‚§ Paging ī‚§ Wait times skewed (ex : latch free) ī‚§ Erratic response times ( ex : ls ) 1. Oracle 1) Waits > CPU ? ī‚§ tune waits 1) CPU > 100% ? ī‚§ tune top CPU SQL 1) Else ī‚§ It’s the application Oracle LoadOracle Load (AAS)(AAS) Top SessionTop Session Top WaitTop Wait Top SQLTop SQL SQL DetailSQL Detail Session DetailSession Detail File DetailFile DetailObject DetailObject Detail Wait DetailWait Detail HostHost AAS >AAS > #CPU#CPU AAS > 1AAS > 1 Waits >Waits > CPUCPU CPU >CPU > WaitsWaits CPUCPU MemoryMemory
  • 42. Summary 1.Database - AAS ī‚§ Profile database ī‚§ Use wait interface and graphics ī‚§ Identify machine, application, database or SQL 1.SQL - VST ī‚§ Indexes, stats, execution path ī‚§ Visual SQL Tuning

Editor's Notes

  1. In Oracle Support I learned more faster than I think I could have anywhere. Porting gave me my first appreciation for the shareable nature of Oracle code and also a bit of disbelief that it worked as well as it did. Oracle France gave me an opportunity to concentrate on the Oracle kernel. At Oracle France I had 3 amazing experiences. First was being sent to the Europecar site where I first met a couple of the people who would later become the founding members of the Oaktable, James Morle and Anjo Kolk. The Europecar site introduced me to a fellow name Roger Sanders who first showed me the wait interface before anyone knew what it was. Roger not only used it but read it directly from shared memory without using SQL. Soon after Europecar I began to be sent often to benchmarks at Digital Europe. These benchmarks were some of my favorite work at Oracle. The benchmarks usually consisted of installing some unknown Oracle customer application and then having a few days to make it run as fast as possible. I first started using TCL/TK and direct shared memory access (DMA) at Digital Europe and got solid hands on tuning experience testing things like striping redo and proving it was faster long before people gave up arguing that this was bad from a theoretical point of view. Finally in France, my boss, Jean Yves Caleca was by far the best boss I ever had, but on top of that he was wonderful at exploring the depths of Oracle and explaining it to others, teaching me much about the internals of block structure, UNDO, REDO and Freelsits. I came back from France wanting to do performance work and especially graphical monitoring. The kernel performance group had limited scope in that domain, so I left for a dot com where I had my first run as the sole DBA for everything, backup, recovery, performance, installation and administration. I was called away by Quest who had my favorite performance tool Spotlight. It turns out thought that scope for expanding Spotlight was limited so I jumped at the chance in 2002 to restructure Oracle OEM. The work at OEM I’m proud of but still want to do much more to make performance tuning faster, easier and more graphical.
  2. In Oracle Support I learned more faster than I think I could have anywhere. Porting gave me my first appreciation for the shareable nature of Oracle code and also a bit of disbelief that it worked as well as it did. Oracle France gave me an opportunity to concentrate on the Oracle kernel. At Oracle France I had 3 amazing experiences. First was being sent to the Europecar site where I first met a couple of the people who would later become the founding members of the Oaktable, James Morle and Anjo Kolk. The Europecar site introduced me to a fellow name Roger Sanders who first showed me the wait interface before anyone knew what it was. Roger not only used it but read it directly from shared memory without using SQL. Soon after Europecar I began to be sent often to benchmarks at Digital Europe. These benchmarks were some of my favorite work at Oracle. The benchmarks usually consisted of installing some unknown Oracle customer application and then having a few days to make it run as fast as possible. I first started using TCL/TK and direct shared memory access (DMA) at Digital Europe and got solid hands on tuning experience testing things like striping redo and proving it was faster long before people gave up arguing that this was bad from a theoretical point of view. Finally in France, my boss, Jean Yves Caleca was by far the best boss I ever had, but on top of that he was wonderful at exploring the depths of Oracle and explaining it to others, teaching me much about the internals of block structure, UNDO, REDO and Freelsits. I came back from France wanting to do performance work and especially graphical monitoring. The kernel performance group had limited scope in that domain, so I left for a dot com where I had my first run as the sole DBA for everything, backup, recovery, performance, installation and administration. I was called away by Quest who had my favorite performance tool Spotlight. It turns out thought that scope for expanding Spotlight was limited so I jumped at the chance in 2002 to restructure Oracle OEM. The work at OEM I’m proud of but still want to do much more to make performance tuning faster, easier and more graphical.
  3. In Oracle Support I learned more faster than I think I could have anywhere. Porting gave me my first appreciation for the shareable nature of Oracle code and also a bit of disbelief that it worked as well as it did. Oracle France gave me an opportunity to concentrate on the Oracle kernel. At Oracle France I had 3 amazing experiences. First was being sent to the Europecar site where I first met a couple of the people who would later become the founding members of the Oaktable, James Morle and Anjo Kolk. The Europecar site introduced me to a fellow name Roger Sanders who first showed me the wait interface before anyone knew what it was. Roger not only used it but read it directly from shared memory without using SQL. Soon after Europecar I began to be sent often to benchmarks at Digital Europe. These benchmarks were some of my favorite work at Oracle. The benchmarks usually consisted of installing some unknown Oracle customer application and then having a few days to make it run as fast as possible. I first started using TCL/TK and direct shared memory access (DMA) at Digital Europe and got solid hands on tuning experience testing things like striping redo and proving it was faster long before people gave up arguing that this was bad from a theoretical point of view. Finally in France, my boss, Jean Yves Caleca was by far the best boss I ever had, but on top of that he was wonderful at exploring the depths of Oracle and explaining it to others, teaching me much about the internals of block structure, UNDO, REDO and Freelsits. I came back from France wanting to do performance work and especially graphical monitoring. The kernel performance group had limited scope in that domain, so I left for a dot com where I had my first run as the sole DBA for everything, backup, recovery, performance, installation and administration. I was called away by Quest who had my favorite performance tool Spotlight. It turns out thought that scope for expanding Spotlight was limited so I jumped at the chance in 2002 to restructure Oracle OEM. The work at OEM I’m proud of but still want to do much more to make performance tuning faster, easier and more graphical.
  4. What allows Oracle, all the dials and knobs, to be the fastest, most robust database on the market also make it one of the most complicated on the market. For those few users that know and love the 1000s of performance options in Oracle, access to those performance options through sql and C code is the defacto standard. For seasoned users it is often difficult to understand why anyone would want to be limited by a GUI which can often be slower, and almost always lacking the latest commands allowed through interfaces such as SQL and C. On the OEM side, when a new tuning feature in the kernel is externalized in OEM (Oracle Enterprise Manager) it is often difficult to see the forest for the tree, or where and how that new feature fits into the grand scheme of things.
  5. This presentation presented a challenge because many of the concepts were like the chicken and the egg. In order to explain one I needed the other. I ’ve tried to keep the subjects as linear as possible but sometimes I interweave from one to another.
  6. In order to tune an Oracle database the first step in a complete analysis is to verify the machine because there are a couple of factors that can only be clearly determined by looking at machine statistics. Those two factors are Memory Usage CPU Usage Memory and CPU problems will have tell tale repercussions on Oracle performance statistics and thus can be deduced from just looking at the Oracle statistics, but it is clear just to start with the machine statistics. CPU For CPU, we check the “run queue” which is the number of processes that are ready to run but have to wait for the CPU. A machine free of CPU contention would have a run queue of 0 and could have CPU usage near 100% at the same time. A high CPU usage can be a good sign that the system is being utilized fully. On the other hand a high run queue will indicated that there is more demand for CPU than CPU power available. High run queue can be determined via Oracle statistics by looking at ASH data and seeing if more sessions are marked as being on the CPU than the number of CPUs available. For example if there are 4 sessions average active on CPU in the ASH data and only 2 CPUs then the machine is CPU bound. Solutions for high run queue are either to add more processors or reduce the load on the CPU. If the CPU is mainly being used by Oracle, then that is going to mean tuning the application and ther SQL queries. Memory If the machine is paging out to disk it means there is a memory crunch and can dramatically slow down Oracle. Oracle will sometimes indicate a paging problem through a spike in “latch free” waits but the only guarenteed method of diagnosing this problem is looking at the machine statistics. Machines have statistics for paging and free memory. Often there can be some free memory even when there is paging out because machines start paging out before memory is completely filled. Solutions if the machine is paging out are either to add more memory or to reduce memory usage. Memory usage can be reduced by reducing Oracle cache sizes or reducing Oracle session memory usage.