SlideShare une entreprise Scribd logo
1  sur  42
Oracle Database Performance
           Tuning
         Presented By-
        Rahul Gaikwad
What is Database Tuning?
 Database tuning is a group of activities used to
  optimize the performance of a database.
 Goal Of Database Tuning?
    To maximize use of system resources
    To perform task as efficiently
    To work rapidly as possible




www.yogijicreations.com
Why and when should one tune?
 Slow Physical I/O
        -caused by poorly-configured disks
        -caused by unnecessary physical I/O
        -caused by poorly-tuned SQL.
 Excessive CPU usage
        -It means that there is little idle CPU on the system
        -caused by an inadequately-sized system,
        -caused by untuned SQLstatements
        -caused inefficient application programs.
 Latch Contention
        Rarely is latch contention tunable by reconfiguring
  the instance. Rather, latch contention usually is
  resolved through application changes.

www.yogijicreations.com
Causes for low Performance
 Bad Connection Management
 Bad Use of Cursors and the Shared Pool
 Bad SQL
 Use of Nonstandard Initialization Parameters
 Getting Database I/O Wrong
 Redo Log Setup Problems
 Long Full Table Scans
 High Amounts of Recursive (SYS) SQL



www.yogijicreations.com
Where should we do the tuning?
 Database Design
   Poor system performance usually results from a poor database design.
   One should generally normalize to the 3NF.
   Selective denormalization can provide valuable performance
      improvements..
   Application Tuning:
     Approximately 80% of all Oracle system performance problems are
      resolved by coding optimal SQL.
   Memory Tuning:
     By Properly size your database buffers (shared pool, buffer cache, log
      buffer, etc)
     By looking at your wait events, buffer hit ratios, system swapping and
      paging, etc.
   Disk I/O Tuning:
     Database files needs to be properly sized.
     Also look for frequent disk sorts, full table scans, data fragmentation, etc.
   Eliminate Database Contention:
     Study database locks, latches and wait events carefully and eliminate
      where possible.
   Tune the Operating System:
        www.yogijicreations.com
     Monitor and tune operating system CPU, I/O and memory utilization.
Optimizing the optimizer
 Optimizer inputs


Table and index                Cardinality
   Structure                   Estimates




                          DB parameters        IO and CPU
Object Statistics
                           And config           Estimates




                                             System Statistics   Cost estimate




     www.yogijicreations.com
Database Statistics

 Database statistics provide information on
  the type of load on the database, as well as
  the internal and external resources used
  by the database.
Performance Data Statistics
                      Time Model

           SQL
                     Wait

           Metrics

   Stats
                       Sessions
Wait Events
 Wait events are statistics that indicate that it
  have to wait for an event to complete before
  being able to continue the processing.
 common examples of the waits-
       Application: locks waits caused by row level locking
       Commit: waits for redo log write confirmation after a
        commit
       Idle: signify the session is inactive
       Network: waits for data to be sent over the network
       User I/O: wait for blocks to be read off a disk
Time Model Statistics

 The V$SESS_TIME_MODEL and V$SYS_TIME_MODEL
  views provide time model statistics
 The most important of the time model statistics is DB time.
 This statistics represents the total time spent in
  database calls and is a indicator of the total instance
  workload.
 It is calculated by aggregating the CPU and wait times
  of all sessions
 DB time is measured cumulatively from the time that the
  instance was started.
 For example, a instance that has been running for 30
  minutes could have four active user sessions whose
  cumulative DB time is approximately 120 minutes.
Active Session History (ASH)

 The V$ACTIVE_SESSION_HISTORY view provides
  sampled session activity in the instance.

 Active sessions are sampled every second and are
  stored in a circular buffer in SGA.

 Active Session includes any session that was on the
  CPU at the time of sampling.
System and Session Statistics
 A large number of cumulative database statistics are
  available on a system and session level through the
  V$SYSSTAT and V$SESSTAT views.
 Operating System Statistics
       Operating system statistics provide information on the usage
        and performance of the main hardware components of the
        system, as well as the performance of the operating system
        itself.
       It is always best to consider operating system statistics as a
        diagnostic tool, similar to the way many doctors use body
        temperature, pulse rate, and patient pain when making a
        diagnosis..
 Operating system statistics include the following:
       CPU Statistics
       Virtual Memory Statistics
       Disk Statistics
       Network Statistics
Automatic Workload Repository
 The Automatic Workload Repository (AWR) collects, processes, and
  maintains performance statistics for problem detection and self-tuning
  purposes.

 This data is stored both in memory and in the database.

 AWR include:
     –   Time model statistics i.e. V$SYS_TIME_MODEL and
         V$SESS_TIME_MODEL views
     –   Some of the system and session statistics collected in the V$SYSSTAT and
         V$SESSTAT views
     –   Active Session History (ASH) statistics, representing the history of recent
         sessions activity

 AWR automatically generates snapshots of the performance data
  once every hour
  and collects the statistics in the workload repository.
Metric
 A metric is defined as the rate of change in
  some cumulative statistic.

 That rate can be measured against time,
  transactions, or database calls.

 For example, the number database calls per second is
  a metric.

 A history of recent metric values is available through
  V$ views.
Tools or Utilities for PT

   V$SQL_PLAN
    ◦ Find SQLs with high resource costs

   EXPLAIN PLAN & DBMS_STAT
    ◦ Determine the execution plan

   SQL Trace/Tkprof
    ◦ Best drilldown at the session level
V$SQL_PLAN
   Used to display the execution plan of a SQL
    statement:

   After the statement has executed, you can
    display the plan by querying the
    V$SQL_PLAN view.

   The V$SQL_PLAN_STATISTICS view
    provides the actual execution statistics for
    every operation in the plan, such as the
    number of output rows and elapsed time.

                              www.yogijicreations.com
EXPLAIN PLAN
   The EXPLAIN PLAN statement displays execution plans for
    SELECT, UPDATE, INSERT, and DELETE statements.

   A statement's execution plan is the sequence of operations Oracle
    performs to run the statement.

   The row source tree is the core of the execution plan. It shows :
       ordering of the tables
       access method for each table
       join method for tables
       Data operations like filter, sort, or aggregation


   The plan table Also contains information :
       Optimization, such as the cost and cardinality of each operation
       Partitioning, such as the set of accessed partitions
       Parallel execution, such as the distribution method of join inputs




                                                    www.yogijicreations.com
PLAN_TABLE Output Table
                   The PLAN_TABLE is automatically created to
                    hold the output of an EXPLAIN PLAN statement
                    for all users.

                   PLAN_TABLE is the default sample output table
                    into which the EXPLAIN PLAN statement
                    inserts rows describing execution plans.

                   While a PLAN_TABLE table is automatically set
                    up for each user, you can use the SQL script
                    utlxplan.sql to manually create a local
                    PLAN_TABLE in your schema.


www.yogijicreations.com
uses EXPLAIN PLAN
 To examine a SQL statement that
  Select employee_id, job_title, salary, and
  department_name for the employees
  whose IDs are less than 103.
 Example Using EXPLAIN PLAN
    SELECT e.employee_id, j.job_title, e.salary,
    d.department_name
    FROM employees e, jobs j, departments d
    WHERE e.employee_id < 103
    AND e.job_id = j.job_id
    AND e.department_id = d.department_id;
                              www.yogijicreations.com
EXPLAIN PLAN Output
-----------------------------------------------------------------------------------
| Id | Operation                                        | Name         |Rows        |Bytes   | Cost (%CPU)|
-----------------------------------------------------------------------------------
| 0 | SELECT STATEMENT                                  |              |3           | 189    | 10 (10)|
| 1 | NESTED LOOPS                                                     |            |3       | 189      | 10
    (10)|
| 2 | NESTED LOOPS                                                     |            |3       | 141       | 7 (15)|
|* 3 | TABLE ACCESS FULL                                | EMPLOYEES | 3 | 60                 | 4 (25)|
| 4 | TABLE ACCESS BY INDEX ROWID | JOBS                               | 19         | 513    | 2 (50)|
|* 5 | INDEX UNIQUE SCAN                                | JOB_ID_PK | 1             |         |      |
| 6 | TABLE ACCESS BY INDEX ROWID | DEPARTMENTS | 27                                         | 432       | 2 (50)|
|* 7 | INDEX UNIQUE SCAN                                | DEPT_ID_PK | 1             |       |       |
-----------------------------------------------------------------------------------
Predicate Information (identified by operation id):
---------------------------------------------------
3 - filter("E"."EMPLOYEE_ID"<103)
5 - access("E"."JOB_ID"="J"."JOB_ID")
7 - access("E"."DEPARTMENT_ID"="D"."DEPARTMENT_ID")


                                                                       www.yogijicreations.com
Steps of Execution Plan
                 Step 3 reads all rows of the employees table.
                 Step 5 looks up each job_id in JOB_ID_PK index and finds the
                 rowids of the associated rows in the jobs table.
                 Step 4 retrieves the rows with rowids that were returned by Step
                 5 from the jobs table.
                 Step 7 looks up each department_id in DEPT_ID_PK index and
                 finds the rowids of the associated rows in the departments table.
                 Step 6 retrieves the rows with rowids that were returned by Step
                 7 from the departments table.
                 The following steps in Example operate on rows returned by the
                 previous row source:
                 Step 2 performs the nested loop operation on job_id in the jobs
                 and employees tables, accepting row sources from Steps 3 and
                 4, joining each row from Step 3 source to its corresponding row
                 in Step 4, and returning the resulting rows to Step 2.
                 Step 1 performs the nested loop operation, accepting row
                 sources from Step2 and Step6, joining each row from Step 2
                 source to its corresponding row in Step 6, and returning the
                 resulting rows to Step 1.
www.yogijicreations.com
www.yogijicreations.com
Full Table Scans
 This type of scan reads all rows from a table
  and filters out those that do not meet the
  selection criteria.
 During a full table scan, all blocks in the table
  that are under the high water mark are
  scanned.
 The high water mark indicates the amount of
  used space, or space that had been formatted
  to receive data.
 Each row is examined to determine whether it
  satisfies the statement's WHERE clause.


                              www.yogijicreations.com
Rowid Scans
 The rowid of a row specifies the data files and
  data block containing the row and the location of
  the row in that block.
 Locating a row by specifying its rowid is the
  fastest way to retrieve a single row, because the
  exact location of the row in the database is
  specified.
 To access a table by rowid, Oracle first obtains
  the rowids of the selected rows, either from the
  statement's WHERE clause or through an index
  scan of one or more of the table's indexes.
 Oracle then locates each selected row in the table
  based on its rowid.
                              www.yogijicreations.com
Index Scans
                In this method, a row is retrieved by traversing the index, using the indexed column
                 values specified by the statement.
                An index scan retrieves data from an index based on the value of one or more columns
                 in the index.
                 To perform an index scan, Oracle searches the index for the indexed column values
                 accessed by the statement.
                If the statement accesses only columns of the index, then Oracle reads the indexed
                 column values directly from the index, rather than from the table.
                The index contains not only the indexed value, but also the rowids of rows in the table
                 having that value.
                 Therefore, if the statement accesses other columns in addition to the indexed columns,
                 then Oracle can find the rows in the table by using either a table access by rowid or a
                 cluster scan.
                An index scan types:
                     Assessing I/O for Blocks, not Rows
                     Index Unique Scans
                     Index Range Scans
                     Index Range Scans Descending
                     Index Skip Scans
                     Full Scans
                     Fast Full Index Scans
                     Index Joins
                     Bitmap Indexes



www.yogijicreations.com
SINGLE TABLE LOOKUP

 Index or table scan?
 Avoid accidental table scans

 Optimize indexes
     best combination of concatenated indexes
 Optimize     necessary table scans
     Vertical/Horizontal partitioning
1000

                                   Full Scan no caching

                                   Index sorted data, no caching

                                   Index unsorted, cached data

                                   Full Table scan, cached data




                   100
Elasped Time (s)




                     10




                                                                        Break even points for index vs table scan




                     1
                          0   10          20                30     40              50                 60            70   80   90   100

                                                                         Pct of table accessed
Concatenated Index Effectiveness


last,first,birthyear,id       3
                                             SELECT cust_id
                                             FROM sh.customers c
                                             WHERE cust_first_name = 'Connor'
                                             AND cust_last_name = 'Bishop'
  last,first,BirthYear        4
                                             AND cust_year_of_birth = 1976;




     last+first name          6




           last name              63




                None                                                                                    1459




                          0            200      400       600                800   1000   1200   1400          1600

                                                                Logical IO
BITMAP INDEXES
BITMAP INDEXES


                    10
Elapsed Time (s)




                     1




                    0.1




                   0.01
                          1   10            100            1000                10000           100000   1000000
                                                  Distinct values in table

                                   Bitmap index      B*-Tree index           Full table scan
VERTICAL PARTITIONING
Joins
OPTIMIZING JOINS
 Best   join order
     Eliminate rows as early as possible
 Join   Type:
   Nested loops
     Optimize the join index

   Sort merge
     Avoid, esp. if memory scarce

   Hash join
     Avoid multi-pass executions
NESTED LOOPS JOIN


           prod_id,channel_id,cust_id,time_id,promo_id       2.2




                                               time_id        3.14
Indexing




                                   prod_id,channel_id                23.43




                                              prod_id                   48.36



                                                                                                                        546.55

                                             No Index




                                                         0                   100   200         300          400   500            600
                                                                                         Elapsed time (s)
SORT-MERGE AND HASH JOIN
                   250




                   200
Elapsed Time (s)




                   150

                                                          Disk Sort


                   100




                                                                                                        In Memory
                    50       Multi pass disk sort   Single pass disk sort




                     0                                                                          In Memory
                         1                          10                                    100                       1000
                                                                Workarea Memory (MB)




                                                         Hash Join      Sort Merge Join
BITMAP JOIN INDEX
BITMAP JOIN PERFORMANCE

                    Full table scan


                                                                                                      13,480
   Access Path




                     Bitmap index                       1,524




                 Bitmap Join index          68




                                      0          2000           4000   6000        8000   10000   12000        14000
                                                                          Logical IO


SELECT SUM (amount_sold)
FROM customers JOIN sales s USING (cust_id) WHERE
cust_email='flint.jeffreys@company2.com';
SORTING – WHAT WE EXPECT



                                                                        Multi-pass
                                                                        Disk Sort
Time




                                                   Single Pass
                                                   Disk Sort

       Memory Sort



                                  PGA Memory available (MB)

                     Table/Index IO    CPU Time       Temp Segment IO
DML

                                                      DML TUNING - INDEXES

                             7                                                      16,316



                             6                                             14,285



                             5                                         12,727
Number of indexes




                             4                                10,719



                             3                        8,691



                             2                6,671



                    1 (PK only)               1,191



                                  0   2,000       4,000           6,000          8,000        10,000     12,000   14,000   16,000   18,000
                                                                                Logical reads required
MULTI-TABLE INSERT




Multi-table insert




                                                                  Insert US
                                                                  Insert EMEA
                                                                  Insert both




     Two Inserts




                     0   1     2          3           4   5   6
                                   Elapsed time (s)
MERGE             3.32




                                                                                   Update
                                                                                   Insert
                                                                                   Merge




INSERT + UPDATE              3.89                               3.71




                  0   1          2   3          4           5          6   7   8
                                         Elapsed Time (s)
Top 10 Oracle SQL tuning
tips
 1.    Design and develop with performance in mind
 2.    Establish a tuning environment
 3.    Index wisely
 4.    Reduce parsing
 5.    Take advantage of Cost Based Optimizer
 6.    Avoid accidental table scans
 7.    Optimize necessary table scans
 8.    Optimize joins
 9.    Use array processing
 10.   Consider PL/SQL for “tricky” SQL

 www.yogijicreations.com
www.yogijicreations.com   For queries: info@yogijicreations.com

Contenu connexe

Tendances

Tanel Poder - Troubleshooting Complex Oracle Performance Issues - Part 2
Tanel Poder - Troubleshooting Complex Oracle Performance Issues - Part 2Tanel Poder - Troubleshooting Complex Oracle Performance Issues - Part 2
Tanel Poder - Troubleshooting Complex Oracle Performance Issues - Part 2Tanel Poder
 
Oracle db performance tuning
Oracle db performance tuningOracle db performance tuning
Oracle db performance tuningSimon Huang
 
Oracle Database Performance Tuning Concept
Oracle Database Performance Tuning ConceptOracle Database Performance Tuning Concept
Oracle Database Performance Tuning ConceptChien Chung Shen
 
SQL Monitoring in Oracle Database 12c
SQL Monitoring in Oracle Database 12cSQL Monitoring in Oracle Database 12c
SQL Monitoring in Oracle Database 12cTanel Poder
 
Oracle statistics by example
Oracle statistics by exampleOracle statistics by example
Oracle statistics by exampleMauro Pagano
 
Oracle architecture ppt
Oracle architecture pptOracle architecture ppt
Oracle architecture pptDeepak Shetty
 
The oracle database architecture
The oracle database architectureThe oracle database architecture
The oracle database architectureAkash Pramanik
 
12. oracle database architecture
12. oracle database architecture12. oracle database architecture
12. oracle database architectureAmrit Kaur
 
Oracle RAC 19c: Best Practices and Secret Internals
Oracle RAC 19c: Best Practices and Secret InternalsOracle RAC 19c: Best Practices and Secret Internals
Oracle RAC 19c: Best Practices and Secret InternalsAnil Nair
 
Oracle SQL Performance Tuning and Optimization v26 chapter 1
Oracle SQL Performance Tuning and Optimization v26 chapter 1Oracle SQL Performance Tuning and Optimization v26 chapter 1
Oracle SQL Performance Tuning and Optimization v26 chapter 1Kevin Meade
 
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 Whatudaymoogala
 
Oracle Architecture
Oracle ArchitectureOracle Architecture
Oracle ArchitectureNeeraj Singh
 
Sql Server Performance Tuning
Sql Server Performance TuningSql Server Performance Tuning
Sql Server Performance TuningBala Subra
 
Oracle Performance Tools of the Trade
Oracle Performance Tools of the TradeOracle Performance Tools of the Trade
Oracle Performance Tools of the TradeCarlos Sierra
 
Database backup & recovery
Database backup & recoveryDatabase backup & recovery
Database backup & recoveryMustafa Khan
 
Oracle database performance tuning
Oracle database performance tuningOracle database performance tuning
Oracle database performance tuningAbishek V S
 
Basic oracle-database-administration
Basic oracle-database-administrationBasic oracle-database-administration
Basic oracle-database-administrationsreehari orienit
 

Tendances (20)

Tanel Poder - Troubleshooting Complex Oracle Performance Issues - Part 2
Tanel Poder - Troubleshooting Complex Oracle Performance Issues - Part 2Tanel Poder - Troubleshooting Complex Oracle Performance Issues - Part 2
Tanel Poder - Troubleshooting Complex Oracle Performance Issues - Part 2
 
Oracle db performance tuning
Oracle db performance tuningOracle db performance tuning
Oracle db performance tuning
 
Oracle Database Performance Tuning Concept
Oracle Database Performance Tuning ConceptOracle Database Performance Tuning Concept
Oracle Database Performance Tuning Concept
 
SQL Monitoring in Oracle Database 12c
SQL Monitoring in Oracle Database 12cSQL Monitoring in Oracle Database 12c
SQL Monitoring in Oracle Database 12c
 
Oracle statistics by example
Oracle statistics by exampleOracle statistics by example
Oracle statistics by example
 
Oracle architecture ppt
Oracle architecture pptOracle architecture ppt
Oracle architecture ppt
 
The oracle database architecture
The oracle database architectureThe oracle database architecture
The oracle database architecture
 
12. oracle database architecture
12. oracle database architecture12. oracle database architecture
12. oracle database architecture
 
Oracle RAC 19c: Best Practices and Secret Internals
Oracle RAC 19c: Best Practices and Secret InternalsOracle RAC 19c: Best Practices and Secret Internals
Oracle RAC 19c: Best Practices and Secret Internals
 
Oracle DBA
Oracle DBAOracle DBA
Oracle DBA
 
Analyzing awr report
Analyzing awr reportAnalyzing awr report
Analyzing awr report
 
Oracle SQL Performance Tuning and Optimization v26 chapter 1
Oracle SQL Performance Tuning and Optimization v26 chapter 1Oracle SQL Performance Tuning and Optimization v26 chapter 1
Oracle SQL Performance Tuning and Optimization v26 chapter 1
 
Less10 undo
Less10 undoLess10 undo
Less10 undo
 
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
 
Oracle Architecture
Oracle ArchitectureOracle Architecture
Oracle Architecture
 
Sql Server Performance Tuning
Sql Server Performance TuningSql Server Performance Tuning
Sql Server Performance Tuning
 
Oracle Performance Tools of the Trade
Oracle Performance Tools of the TradeOracle Performance Tools of the Trade
Oracle Performance Tools of the Trade
 
Database backup & recovery
Database backup & recoveryDatabase backup & recovery
Database backup & recovery
 
Oracle database performance tuning
Oracle database performance tuningOracle database performance tuning
Oracle database performance tuning
 
Basic oracle-database-administration
Basic oracle-database-administrationBasic oracle-database-administration
Basic oracle-database-administration
 

En vedette

Database Performance Tuning Introduction
Database  Performance Tuning IntroductionDatabase  Performance Tuning Introduction
Database Performance Tuning IntroductionMyOnlineITCourses
 
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)Guy Harrison
 
Database performance tuning and query optimization
Database performance tuning and query optimizationDatabase performance tuning and query optimization
Database performance tuning and query optimizationDhani Ahmad
 
Oracle Oracle Performance Tuning
Oracle Oracle Performance Tuning Oracle Oracle Performance Tuning
Oracle Oracle Performance Tuning Kernel Training
 
Performance tuning and optimization (ppt)
Performance tuning and optimization (ppt)Performance tuning and optimization (ppt)
Performance tuning and optimization (ppt)Harish Chand
 
Database Performance Tuning
Database Performance Tuning Database Performance Tuning
Database Performance Tuning Arno Huetter
 
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 Casesvbarun01
 
Analyzing and Interpreting AWR
Analyzing and Interpreting AWRAnalyzing and Interpreting AWR
Analyzing and Interpreting AWRpasalapudi
 
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 Windowsjstorm
 
Oracle 10g Performance: chapter 00 intro live_short
Oracle 10g Performance: chapter 00 intro live_shortOracle 10g Performance: chapter 00 intro live_short
Oracle 10g Performance: chapter 00 intro live_shortKyle Hailey
 
OOUG - Oracle Performance Tuning with AAS
OOUG - Oracle Performance Tuning with AASOOUG - Oracle Performance Tuning with AAS
OOUG - Oracle Performance Tuning with AASKyle Hailey
 
Oracle Performance Tuning Fundamentals
Oracle Performance Tuning FundamentalsOracle Performance Tuning Fundamentals
Oracle Performance Tuning FundamentalsCarlos Sierra
 
Oracle 11g R2 RAC implementation and concept
Oracle 11g R2 RAC implementation and conceptOracle 11g R2 RAC implementation and concept
Oracle 11g R2 RAC implementation and conceptSantosh Kangane
 
NoSQL: An Architects Perspective
NoSQL: An Architects PerspectiveNoSQL: An Architects Perspective
NoSQL: An Architects PerspectiveEberhard Wolff
 
Capacity Management for SAN
Capacity Management for SANCapacity Management for SAN
Capacity Management for SANMetron
 
oracle cloud with 2 nodes processing
oracle cloud with 2 nodes processingoracle cloud with 2 nodes processing
oracle cloud with 2 nodes processingmahdi ahmadi
 
IOUG Collaborate 2014 ASH/AWR Deep Dive
IOUG Collaborate 2014 ASH/AWR Deep DiveIOUG Collaborate 2014 ASH/AWR Deep Dive
IOUG Collaborate 2014 ASH/AWR Deep DiveKellyn Pot'Vin-Gorman
 
Oracle Diagnostics : Latches and Enqueues
Oracle Diagnostics : Latches and EnqueuesOracle Diagnostics : Latches and Enqueues
Oracle Diagnostics : Latches and EnqueuesHemant K Chitale
 
Indexing Strategies for Oracle Databases - Beyond the Create Index Statement
Indexing Strategies for Oracle Databases - Beyond the Create Index StatementIndexing Strategies for Oracle Databases - Beyond the Create Index Statement
Indexing Strategies for Oracle Databases - Beyond the Create Index StatementSean Scott
 

En vedette (20)

Database Performance Tuning Introduction
Database  Performance Tuning IntroductionDatabase  Performance Tuning Introduction
Database Performance Tuning Introduction
 
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)
 
Database performance tuning and query optimization
Database performance tuning and query optimizationDatabase performance tuning and query optimization
Database performance tuning and query optimization
 
Oracle Oracle Performance Tuning
Oracle Oracle Performance Tuning Oracle Oracle Performance Tuning
Oracle Oracle Performance Tuning
 
Performance tuning and optimization (ppt)
Performance tuning and optimization (ppt)Performance tuning and optimization (ppt)
Performance tuning and optimization (ppt)
 
Performance tuning in sql server
Performance tuning in sql serverPerformance tuning in sql server
Performance tuning in sql server
 
Database Performance Tuning
Database Performance Tuning Database Performance Tuning
Database Performance Tuning
 
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
 
Analyzing and Interpreting AWR
Analyzing and Interpreting AWRAnalyzing and Interpreting AWR
Analyzing and Interpreting AWR
 
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 10g Performance: chapter 00 intro live_short
Oracle 10g Performance: chapter 00 intro live_shortOracle 10g Performance: chapter 00 intro live_short
Oracle 10g Performance: chapter 00 intro live_short
 
OOUG - Oracle Performance Tuning with AAS
OOUG - Oracle Performance Tuning with AASOOUG - Oracle Performance Tuning with AAS
OOUG - Oracle Performance Tuning with AAS
 
Oracle Performance Tuning Fundamentals
Oracle Performance Tuning FundamentalsOracle Performance Tuning Fundamentals
Oracle Performance Tuning Fundamentals
 
Oracle 11g R2 RAC implementation and concept
Oracle 11g R2 RAC implementation and conceptOracle 11g R2 RAC implementation and concept
Oracle 11g R2 RAC implementation and concept
 
NoSQL: An Architects Perspective
NoSQL: An Architects PerspectiveNoSQL: An Architects Perspective
NoSQL: An Architects Perspective
 
Capacity Management for SAN
Capacity Management for SANCapacity Management for SAN
Capacity Management for SAN
 
oracle cloud with 2 nodes processing
oracle cloud with 2 nodes processingoracle cloud with 2 nodes processing
oracle cloud with 2 nodes processing
 
IOUG Collaborate 2014 ASH/AWR Deep Dive
IOUG Collaborate 2014 ASH/AWR Deep DiveIOUG Collaborate 2014 ASH/AWR Deep Dive
IOUG Collaborate 2014 ASH/AWR Deep Dive
 
Oracle Diagnostics : Latches and Enqueues
Oracle Diagnostics : Latches and EnqueuesOracle Diagnostics : Latches and Enqueues
Oracle Diagnostics : Latches and Enqueues
 
Indexing Strategies for Oracle Databases - Beyond the Create Index Statement
Indexing Strategies for Oracle Databases - Beyond the Create Index StatementIndexing Strategies for Oracle Databases - Beyond the Create Index Statement
Indexing Strategies for Oracle Databases - Beyond the Create Index Statement
 

Similaire à Oracle database performance tuning

Sql and PL/SQL Best Practices I
Sql and PL/SQL Best Practices ISql and PL/SQL Best Practices I
Sql and PL/SQL Best Practices ICarlos Oliveira
 
05_DP_300T00A_Optimize.pptx
05_DP_300T00A_Optimize.pptx05_DP_300T00A_Optimize.pptx
05_DP_300T00A_Optimize.pptxKareemBullard1
 
Optimizing Data Accessin Sq Lserver2005
Optimizing Data Accessin Sq Lserver2005Optimizing Data Accessin Sq Lserver2005
Optimizing Data Accessin Sq Lserver2005rainynovember12
 
R12 d49656 gc10-apps dba 07
R12 d49656 gc10-apps dba 07R12 d49656 gc10-apps dba 07
R12 d49656 gc10-apps dba 07zeesniper
 
Presentación Oracle Database Migración consideraciones 10g/11g/12c
Presentación Oracle Database Migración consideraciones 10g/11g/12cPresentación Oracle Database Migración consideraciones 10g/11g/12c
Presentación Oracle Database Migración consideraciones 10g/11g/12cRonald Francisco Vargas Quesada
 
SQL Server 2008 Development for Programmers
SQL Server 2008 Development for ProgrammersSQL Server 2008 Development for Programmers
SQL Server 2008 Development for ProgrammersAdam Hutson
 
Oracle Query Optimizer - An Introduction
Oracle Query Optimizer - An IntroductionOracle Query Optimizer - An Introduction
Oracle Query Optimizer - An Introductionadryanbub
 
Overview of query evaluation
Overview of query evaluationOverview of query evaluation
Overview of query evaluationavniS
 
Cost Based Optimizer - Part 1 of 2
Cost Based Optimizer - Part 1 of 2Cost Based Optimizer - Part 1 of 2
Cost Based Optimizer - Part 1 of 2Mahesh Vallampati
 
Explain the explain_plan
Explain the explain_planExplain the explain_plan
Explain the explain_planMaria Colgan
 
Sql server lesson12
Sql server lesson12Sql server lesson12
Sql server lesson12Ala Qunaibi
 
Sql server lesson12
Sql server lesson12Sql server lesson12
Sql server lesson12Ala Qunaibi
 
Getting optimal performance from oracle e-business suite presentation
Getting optimal performance from oracle e-business suite presentationGetting optimal performance from oracle e-business suite presentation
Getting optimal performance from oracle e-business suite presentationBerry Clemens
 
MemSQL 201: Advanced Tips and Tricks Webcast
MemSQL 201: Advanced Tips and Tricks WebcastMemSQL 201: Advanced Tips and Tricks Webcast
MemSQL 201: Advanced Tips and Tricks WebcastSingleStore
 
Tony Jambu (obscure) tools of the trade for tuning oracle sq ls
Tony Jambu   (obscure) tools of the trade for tuning oracle sq lsTony Jambu   (obscure) tools of the trade for tuning oracle sq ls
Tony Jambu (obscure) tools of the trade for tuning oracle sq lsInSync Conference
 
An Approach to Sql tuning - Part 1
An Approach to Sql tuning - Part 1An Approach to Sql tuning - Part 1
An Approach to Sql tuning - Part 1Navneet Upneja
 
Top 10 tips for Oracle performance
Top 10 tips for Oracle performanceTop 10 tips for Oracle performance
Top 10 tips for Oracle performanceGuy Harrison
 
SQL Server Query Optimization, Execution and Debugging Query Performance
SQL Server Query Optimization, Execution and Debugging Query PerformanceSQL Server Query Optimization, Execution and Debugging Query Performance
SQL Server Query Optimization, Execution and Debugging Query PerformanceVinod Kumar
 
Web Cloud Computing SQL Server - Ferrara University
Web Cloud Computing SQL Server  -  Ferrara UniversityWeb Cloud Computing SQL Server  -  Ferrara University
Web Cloud Computing SQL Server - Ferrara Universityantimo musone
 

Similaire à Oracle database performance tuning (20)

Sql and PL/SQL Best Practices I
Sql and PL/SQL Best Practices ISql and PL/SQL Best Practices I
Sql and PL/SQL Best Practices I
 
05_DP_300T00A_Optimize.pptx
05_DP_300T00A_Optimize.pptx05_DP_300T00A_Optimize.pptx
05_DP_300T00A_Optimize.pptx
 
Optimizing Data Accessin Sq Lserver2005
Optimizing Data Accessin Sq Lserver2005Optimizing Data Accessin Sq Lserver2005
Optimizing Data Accessin Sq Lserver2005
 
R12 d49656 gc10-apps dba 07
R12 d49656 gc10-apps dba 07R12 d49656 gc10-apps dba 07
R12 d49656 gc10-apps dba 07
 
Presentación Oracle Database Migración consideraciones 10g/11g/12c
Presentación Oracle Database Migración consideraciones 10g/11g/12cPresentación Oracle Database Migración consideraciones 10g/11g/12c
Presentación Oracle Database Migración consideraciones 10g/11g/12c
 
SQL Server 2008 Development for Programmers
SQL Server 2008 Development for ProgrammersSQL Server 2008 Development for Programmers
SQL Server 2008 Development for Programmers
 
Oracle Query Optimizer - An Introduction
Oracle Query Optimizer - An IntroductionOracle Query Optimizer - An Introduction
Oracle Query Optimizer - An Introduction
 
Overview of query evaluation
Overview of query evaluationOverview of query evaluation
Overview of query evaluation
 
SQL Tunning
SQL TunningSQL Tunning
SQL Tunning
 
Cost Based Optimizer - Part 1 of 2
Cost Based Optimizer - Part 1 of 2Cost Based Optimizer - Part 1 of 2
Cost Based Optimizer - Part 1 of 2
 
Explain the explain_plan
Explain the explain_planExplain the explain_plan
Explain the explain_plan
 
Sql server lesson12
Sql server lesson12Sql server lesson12
Sql server lesson12
 
Sql server lesson12
Sql server lesson12Sql server lesson12
Sql server lesson12
 
Getting optimal performance from oracle e-business suite presentation
Getting optimal performance from oracle e-business suite presentationGetting optimal performance from oracle e-business suite presentation
Getting optimal performance from oracle e-business suite presentation
 
MemSQL 201: Advanced Tips and Tricks Webcast
MemSQL 201: Advanced Tips and Tricks WebcastMemSQL 201: Advanced Tips and Tricks Webcast
MemSQL 201: Advanced Tips and Tricks Webcast
 
Tony Jambu (obscure) tools of the trade for tuning oracle sq ls
Tony Jambu   (obscure) tools of the trade for tuning oracle sq lsTony Jambu   (obscure) tools of the trade for tuning oracle sq ls
Tony Jambu (obscure) tools of the trade for tuning oracle sq ls
 
An Approach to Sql tuning - Part 1
An Approach to Sql tuning - Part 1An Approach to Sql tuning - Part 1
An Approach to Sql tuning - Part 1
 
Top 10 tips for Oracle performance
Top 10 tips for Oracle performanceTop 10 tips for Oracle performance
Top 10 tips for Oracle performance
 
SQL Server Query Optimization, Execution and Debugging Query Performance
SQL Server Query Optimization, Execution and Debugging Query PerformanceSQL Server Query Optimization, Execution and Debugging Query Performance
SQL Server Query Optimization, Execution and Debugging Query Performance
 
Web Cloud Computing SQL Server - Ferrara University
Web Cloud Computing SQL Server  -  Ferrara UniversityWeb Cloud Computing SQL Server  -  Ferrara University
Web Cloud Computing SQL Server - Ferrara University
 

Plus de Yogiji Creations

Oracle architecture with details-yogiji creations
Oracle architecture with details-yogiji creationsOracle architecture with details-yogiji creations
Oracle architecture with details-yogiji creationsYogiji Creations
 
Oracle backup and recovery
Oracle backup and recoveryOracle backup and recovery
Oracle backup and recoveryYogiji Creations
 
User, roles and privileges
User, roles and privilegesUser, roles and privileges
User, roles and privilegesYogiji Creations
 
Hospital Management System-out patient Detail
Hospital Management System-out patient DetailHospital Management System-out patient Detail
Hospital Management System-out patient DetailYogiji Creations
 

Plus de Yogiji Creations (6)

Rocking presentation
Rocking presentationRocking presentation
Rocking presentation
 
Wi max by yogijicreations
Wi max by yogijicreationsWi max by yogijicreations
Wi max by yogijicreations
 
Oracle architecture with details-yogiji creations
Oracle architecture with details-yogiji creationsOracle architecture with details-yogiji creations
Oracle architecture with details-yogiji creations
 
Oracle backup and recovery
Oracle backup and recoveryOracle backup and recovery
Oracle backup and recovery
 
User, roles and privileges
User, roles and privilegesUser, roles and privileges
User, roles and privileges
 
Hospital Management System-out patient Detail
Hospital Management System-out patient DetailHospital Management System-out patient Detail
Hospital Management System-out patient Detail
 

Dernier

4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptxmary850239
 
Dust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEDust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEaurabinda banchhor
 
Oppenheimer Film Discussion for Philosophy and Film
Oppenheimer Film Discussion for Philosophy and FilmOppenheimer Film Discussion for Philosophy and Film
Oppenheimer Film Discussion for Philosophy and FilmStan Meyer
 
Expanded definition: technical and operational
Expanded definition: technical and operationalExpanded definition: technical and operational
Expanded definition: technical and operationalssuser3e220a
 
Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Seán Kennedy
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptxmary850239
 
Presentation Activity 2. Unit 3 transv.pptx
Presentation Activity 2. Unit 3 transv.pptxPresentation Activity 2. Unit 3 transv.pptx
Presentation Activity 2. Unit 3 transv.pptxRosabel UA
 
Integumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptIntegumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptshraddhaparab530
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Celine George
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4MiaBumagat1
 
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfVirtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfErwinPantujan2
 
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...Nguyen Thanh Tu Collection
 
ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfVanessa Camilleri
 
Activity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationActivity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationRosabel UA
 
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...JojoEDelaCruz
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfTechSoup
 
TEACHER REFLECTION FORM (NEW SET........).docx
TEACHER REFLECTION FORM (NEW SET........).docxTEACHER REFLECTION FORM (NEW SET........).docx
TEACHER REFLECTION FORM (NEW SET........).docxruthvilladarez
 
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...Postal Advocate Inc.
 

Dernier (20)

4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx
 
Dust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEDust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSE
 
Oppenheimer Film Discussion for Philosophy and Film
Oppenheimer Film Discussion for Philosophy and FilmOppenheimer Film Discussion for Philosophy and Film
Oppenheimer Film Discussion for Philosophy and Film
 
Expanded definition: technical and operational
Expanded definition: technical and operationalExpanded definition: technical and operational
Expanded definition: technical and operational
 
Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx
 
Presentation Activity 2. Unit 3 transv.pptx
Presentation Activity 2. Unit 3 transv.pptxPresentation Activity 2. Unit 3 transv.pptx
Presentation Activity 2. Unit 3 transv.pptx
 
Integumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptIntegumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.ppt
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4
 
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfVirtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
 
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
 
LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptxLEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
 
ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdf
 
Activity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationActivity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translation
 
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
 
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptxINCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
 
TEACHER REFLECTION FORM (NEW SET........).docx
TEACHER REFLECTION FORM (NEW SET........).docxTEACHER REFLECTION FORM (NEW SET........).docx
TEACHER REFLECTION FORM (NEW SET........).docx
 
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
 

Oracle database performance tuning

  • 1. Oracle Database Performance Tuning Presented By- Rahul Gaikwad
  • 2. What is Database Tuning?  Database tuning is a group of activities used to optimize the performance of a database.  Goal Of Database Tuning?  To maximize use of system resources  To perform task as efficiently  To work rapidly as possible www.yogijicreations.com
  • 3. Why and when should one tune?  Slow Physical I/O -caused by poorly-configured disks -caused by unnecessary physical I/O -caused by poorly-tuned SQL.  Excessive CPU usage -It means that there is little idle CPU on the system -caused by an inadequately-sized system, -caused by untuned SQLstatements -caused inefficient application programs.  Latch Contention Rarely is latch contention tunable by reconfiguring the instance. Rather, latch contention usually is resolved through application changes. www.yogijicreations.com
  • 4. Causes for low Performance  Bad Connection Management  Bad Use of Cursors and the Shared Pool  Bad SQL  Use of Nonstandard Initialization Parameters  Getting Database I/O Wrong  Redo Log Setup Problems  Long Full Table Scans  High Amounts of Recursive (SYS) SQL www.yogijicreations.com
  • 5. Where should we do the tuning?  Database Design  Poor system performance usually results from a poor database design.  One should generally normalize to the 3NF.  Selective denormalization can provide valuable performance improvements..  Application Tuning:  Approximately 80% of all Oracle system performance problems are resolved by coding optimal SQL.  Memory Tuning:  By Properly size your database buffers (shared pool, buffer cache, log buffer, etc)  By looking at your wait events, buffer hit ratios, system swapping and paging, etc.  Disk I/O Tuning:  Database files needs to be properly sized.  Also look for frequent disk sorts, full table scans, data fragmentation, etc.  Eliminate Database Contention:  Study database locks, latches and wait events carefully and eliminate where possible.  Tune the Operating System: www.yogijicreations.com  Monitor and tune operating system CPU, I/O and memory utilization.
  • 6. Optimizing the optimizer Optimizer inputs Table and index Cardinality Structure Estimates DB parameters IO and CPU Object Statistics And config Estimates System Statistics Cost estimate www.yogijicreations.com
  • 7. Database Statistics  Database statistics provide information on the type of load on the database, as well as the internal and external resources used by the database.
  • 8. Performance Data Statistics Time Model SQL Wait Metrics Stats Sessions
  • 9. Wait Events  Wait events are statistics that indicate that it have to wait for an event to complete before being able to continue the processing.  common examples of the waits-  Application: locks waits caused by row level locking  Commit: waits for redo log write confirmation after a commit  Idle: signify the session is inactive  Network: waits for data to be sent over the network  User I/O: wait for blocks to be read off a disk
  • 10. Time Model Statistics  The V$SESS_TIME_MODEL and V$SYS_TIME_MODEL views provide time model statistics  The most important of the time model statistics is DB time.  This statistics represents the total time spent in database calls and is a indicator of the total instance workload.  It is calculated by aggregating the CPU and wait times of all sessions  DB time is measured cumulatively from the time that the instance was started.  For example, a instance that has been running for 30 minutes could have four active user sessions whose cumulative DB time is approximately 120 minutes.
  • 11. Active Session History (ASH)  The V$ACTIVE_SESSION_HISTORY view provides sampled session activity in the instance.  Active sessions are sampled every second and are stored in a circular buffer in SGA.  Active Session includes any session that was on the CPU at the time of sampling.
  • 12. System and Session Statistics  A large number of cumulative database statistics are available on a system and session level through the V$SYSSTAT and V$SESSTAT views.  Operating System Statistics  Operating system statistics provide information on the usage and performance of the main hardware components of the system, as well as the performance of the operating system itself.  It is always best to consider operating system statistics as a diagnostic tool, similar to the way many doctors use body temperature, pulse rate, and patient pain when making a diagnosis..  Operating system statistics include the following:  CPU Statistics  Virtual Memory Statistics  Disk Statistics  Network Statistics
  • 13. Automatic Workload Repository  The Automatic Workload Repository (AWR) collects, processes, and maintains performance statistics for problem detection and self-tuning purposes.  This data is stored both in memory and in the database.  AWR include: – Time model statistics i.e. V$SYS_TIME_MODEL and V$SESS_TIME_MODEL views – Some of the system and session statistics collected in the V$SYSSTAT and V$SESSTAT views – Active Session History (ASH) statistics, representing the history of recent sessions activity  AWR automatically generates snapshots of the performance data once every hour and collects the statistics in the workload repository.
  • 14. Metric  A metric is defined as the rate of change in some cumulative statistic.  That rate can be measured against time, transactions, or database calls.  For example, the number database calls per second is a metric.  A history of recent metric values is available through V$ views.
  • 15. Tools or Utilities for PT  V$SQL_PLAN ◦ Find SQLs with high resource costs  EXPLAIN PLAN & DBMS_STAT ◦ Determine the execution plan  SQL Trace/Tkprof ◦ Best drilldown at the session level
  • 16. V$SQL_PLAN  Used to display the execution plan of a SQL statement:  After the statement has executed, you can display the plan by querying the V$SQL_PLAN view.  The V$SQL_PLAN_STATISTICS view provides the actual execution statistics for every operation in the plan, such as the number of output rows and elapsed time. www.yogijicreations.com
  • 17. EXPLAIN PLAN  The EXPLAIN PLAN statement displays execution plans for SELECT, UPDATE, INSERT, and DELETE statements.  A statement's execution plan is the sequence of operations Oracle performs to run the statement.  The row source tree is the core of the execution plan. It shows :  ordering of the tables  access method for each table  join method for tables  Data operations like filter, sort, or aggregation  The plan table Also contains information :  Optimization, such as the cost and cardinality of each operation  Partitioning, such as the set of accessed partitions  Parallel execution, such as the distribution method of join inputs www.yogijicreations.com
  • 18. PLAN_TABLE Output Table  The PLAN_TABLE is automatically created to hold the output of an EXPLAIN PLAN statement for all users.  PLAN_TABLE is the default sample output table into which the EXPLAIN PLAN statement inserts rows describing execution plans.  While a PLAN_TABLE table is automatically set up for each user, you can use the SQL script utlxplan.sql to manually create a local PLAN_TABLE in your schema. www.yogijicreations.com
  • 19. uses EXPLAIN PLAN  To examine a SQL statement that Select employee_id, job_title, salary, and department_name for the employees whose IDs are less than 103.  Example Using EXPLAIN PLAN SELECT e.employee_id, j.job_title, e.salary, d.department_name FROM employees e, jobs j, departments d WHERE e.employee_id < 103 AND e.job_id = j.job_id AND e.department_id = d.department_id; www.yogijicreations.com
  • 20. EXPLAIN PLAN Output ----------------------------------------------------------------------------------- | Id | Operation | Name |Rows |Bytes | Cost (%CPU)| ----------------------------------------------------------------------------------- | 0 | SELECT STATEMENT | |3 | 189 | 10 (10)| | 1 | NESTED LOOPS | |3 | 189 | 10 (10)| | 2 | NESTED LOOPS | |3 | 141 | 7 (15)| |* 3 | TABLE ACCESS FULL | EMPLOYEES | 3 | 60 | 4 (25)| | 4 | TABLE ACCESS BY INDEX ROWID | JOBS | 19 | 513 | 2 (50)| |* 5 | INDEX UNIQUE SCAN | JOB_ID_PK | 1 | | | | 6 | TABLE ACCESS BY INDEX ROWID | DEPARTMENTS | 27 | 432 | 2 (50)| |* 7 | INDEX UNIQUE SCAN | DEPT_ID_PK | 1 | | | ----------------------------------------------------------------------------------- Predicate Information (identified by operation id): --------------------------------------------------- 3 - filter("E"."EMPLOYEE_ID"<103) 5 - access("E"."JOB_ID"="J"."JOB_ID") 7 - access("E"."DEPARTMENT_ID"="D"."DEPARTMENT_ID") www.yogijicreations.com
  • 21. Steps of Execution Plan  Step 3 reads all rows of the employees table.  Step 5 looks up each job_id in JOB_ID_PK index and finds the rowids of the associated rows in the jobs table.  Step 4 retrieves the rows with rowids that were returned by Step 5 from the jobs table.  Step 7 looks up each department_id in DEPT_ID_PK index and finds the rowids of the associated rows in the departments table.  Step 6 retrieves the rows with rowids that were returned by Step 7 from the departments table.  The following steps in Example operate on rows returned by the previous row source:  Step 2 performs the nested loop operation on job_id in the jobs and employees tables, accepting row sources from Steps 3 and 4, joining each row from Step 3 source to its corresponding row in Step 4, and returning the resulting rows to Step 2.  Step 1 performs the nested loop operation, accepting row sources from Step2 and Step6, joining each row from Step 2 source to its corresponding row in Step 6, and returning the resulting rows to Step 1. www.yogijicreations.com
  • 23. Full Table Scans  This type of scan reads all rows from a table and filters out those that do not meet the selection criteria.  During a full table scan, all blocks in the table that are under the high water mark are scanned.  The high water mark indicates the amount of used space, or space that had been formatted to receive data.  Each row is examined to determine whether it satisfies the statement's WHERE clause. www.yogijicreations.com
  • 24. Rowid Scans  The rowid of a row specifies the data files and data block containing the row and the location of the row in that block.  Locating a row by specifying its rowid is the fastest way to retrieve a single row, because the exact location of the row in the database is specified.  To access a table by rowid, Oracle first obtains the rowids of the selected rows, either from the statement's WHERE clause or through an index scan of one or more of the table's indexes.  Oracle then locates each selected row in the table based on its rowid. www.yogijicreations.com
  • 25. Index Scans  In this method, a row is retrieved by traversing the index, using the indexed column values specified by the statement.  An index scan retrieves data from an index based on the value of one or more columns in the index.  To perform an index scan, Oracle searches the index for the indexed column values accessed by the statement.  If the statement accesses only columns of the index, then Oracle reads the indexed column values directly from the index, rather than from the table.  The index contains not only the indexed value, but also the rowids of rows in the table having that value.  Therefore, if the statement accesses other columns in addition to the indexed columns, then Oracle can find the rows in the table by using either a table access by rowid or a cluster scan.  An index scan types:  Assessing I/O for Blocks, not Rows  Index Unique Scans  Index Range Scans  Index Range Scans Descending  Index Skip Scans  Full Scans  Fast Full Index Scans  Index Joins  Bitmap Indexes www.yogijicreations.com
  • 26. SINGLE TABLE LOOKUP  Index or table scan?  Avoid accidental table scans  Optimize indexes  best combination of concatenated indexes  Optimize necessary table scans  Vertical/Horizontal partitioning
  • 27. 1000 Full Scan no caching Index sorted data, no caching Index unsorted, cached data Full Table scan, cached data 100 Elasped Time (s) 10 Break even points for index vs table scan 1 0 10 20 30 40 50 60 70 80 90 100 Pct of table accessed
  • 28. Concatenated Index Effectiveness last,first,birthyear,id 3 SELECT cust_id FROM sh.customers c WHERE cust_first_name = 'Connor' AND cust_last_name = 'Bishop' last,first,BirthYear 4 AND cust_year_of_birth = 1976; last+first name 6 last name 63 None 1459 0 200 400 600 800 1000 1200 1400 1600 Logical IO
  • 30. BITMAP INDEXES 10 Elapsed Time (s) 1 0.1 0.01 1 10 100 1000 10000 100000 1000000 Distinct values in table Bitmap index B*-Tree index Full table scan
  • 32. Joins OPTIMIZING JOINS  Best join order  Eliminate rows as early as possible  Join Type:  Nested loops  Optimize the join index  Sort merge  Avoid, esp. if memory scarce  Hash join  Avoid multi-pass executions
  • 33. NESTED LOOPS JOIN prod_id,channel_id,cust_id,time_id,promo_id 2.2 time_id 3.14 Indexing prod_id,channel_id 23.43 prod_id 48.36 546.55 No Index 0 100 200 300 400 500 600 Elapsed time (s)
  • 34. SORT-MERGE AND HASH JOIN 250 200 Elapsed Time (s) 150 Disk Sort 100 In Memory 50 Multi pass disk sort Single pass disk sort 0 In Memory 1 10 100 1000 Workarea Memory (MB) Hash Join Sort Merge Join
  • 36. BITMAP JOIN PERFORMANCE Full table scan 13,480 Access Path Bitmap index 1,524 Bitmap Join index 68 0 2000 4000 6000 8000 10000 12000 14000 Logical IO SELECT SUM (amount_sold) FROM customers JOIN sales s USING (cust_id) WHERE cust_email='flint.jeffreys@company2.com';
  • 37. SORTING – WHAT WE EXPECT Multi-pass Disk Sort Time Single Pass Disk Sort Memory Sort PGA Memory available (MB) Table/Index IO CPU Time Temp Segment IO
  • 38. DML DML TUNING - INDEXES 7 16,316 6 14,285 5 12,727 Number of indexes 4 10,719 3 8,691 2 6,671 1 (PK only) 1,191 0 2,000 4,000 6,000 8,000 10,000 12,000 14,000 16,000 18,000 Logical reads required
  • 39. MULTI-TABLE INSERT Multi-table insert Insert US Insert EMEA Insert both Two Inserts 0 1 2 3 4 5 6 Elapsed time (s)
  • 40. MERGE 3.32 Update Insert Merge INSERT + UPDATE 3.89 3.71 0 1 2 3 4 5 6 7 8 Elapsed Time (s)
  • 41. Top 10 Oracle SQL tuning tips 1. Design and develop with performance in mind 2. Establish a tuning environment 3. Index wisely 4. Reduce parsing 5. Take advantage of Cost Based Optimizer 6. Avoid accidental table scans 7. Optimize necessary table scans 8. Optimize joins 9. Use array processing 10. Consider PL/SQL for “tricky” SQL www.yogijicreations.com
  • 42. www.yogijicreations.com For queries: info@yogijicreations.com

Notes de l'éditeur

  1. Stupid SQL Joke:An SQL statement walks into a bar and sees two tables.It approaches, and asks “may I join you?”