You are on page 1of 22

7

Reactive Tuning

Copyright © 2006, Oracle. All rights reserved.


Objectives

After completing this lesson, you should be able to do


the following:
• Use Enterprise Manager pages to identify
performance issues
• Eliminate operating system issues

7-2 Copyright © 2006, Oracle. All rights reserved.


Where Is the Problem?

Performance issues can be categorized:


• Operating system (OS)
• Application
• Instance

7-3 Copyright © 2006, Oracle. All rights reserved.


Operating System
OS Issues Application
Instance

Operating system issues:


• Memory
• CPU
• I/O (disk and network)

7-4 Copyright © 2006, Oracle. All rights reserved.


Database Home Page

7-6 Copyright © 2006, Oracle. All rights reserved.


OS Statistics and Enterprise Manager

7-7 Copyright © 2006, Oracle. All rights reserved.


OS Statistics
Statistic Name Description
NUM_CPUS Number of CPUs or processors available
IDLE/BUSY/USER/NICE/SYS_TIME # hundredths of a second that a processor has been
idle/busy…
IOWAIT_TIME The average # hundredths of a second that a processor
has been waiting for I/O to complete
OS_CPU_WAIT_TIME # hundredths of a second that processes have been in a
ready state, waiting to be scheduled
RSRC_MGR_CPU_WAIT_TIME # hundredths of a second Oracle processes have been in
a ready state, waiting for CPU to be available for their
consumer group in the currently active resource plan
VM_PAGE_IN/OUT_BYTES # bytes of data paged in/out due to paging
PHYSICAL_MEMORY_BYTES Total number of bytes of physical memory
# processes either running or in the ready state over the the last
LOAD 60 seconds

NUM_CPU_SOCKETS Number of CPU sockets available

NUM_CPU_CORES Number of CPU cores available

7-8 Copyright © 2006, Oracle. All rights reserved.


Operating System
Application Issues Application
Instance

Application issues can be categorized as:


• Resource serialization
• Relational design
• Session management
• Cursor management
• Program design

7-9 Copyright © 2006, Oracle. All rights reserved.


Operating System
Instance Issues Application
Instance

Instance issues are categorized as:


• Memory
– SGA
– PGA
• I/O
– Physical I/O
– Data placement
• Contention
– Locks
– Latches
– Serialized resources

7-11 Copyright © 2006, Oracle. All rights reserved.


Architecture
Instance
SGA

Sort Global Default Keep Recycle nK Redo Flash


Fixed Shared ASH buffer buffer
extent context buffer buffer log Large Java Streams back
size pool buffer cache cache caches
pool pool cache buffer pool pool pool buffer

PMON SMON RECO MMON MMAN DBWn LGWR CKPT S000 RVWR

QMNC MMNL CTWR ARCn D000


PSP0 CJQ0
FMON
Qnnn

Password Redo log


SYSTEM Temp files
file
Control Change Flashback
files SYSAUX Data file tracking
Spfile logs
file
Undo Archive
log files

7-12 Copyright © 2006, Oracle. All rights reserved.


Performance Management Approach

Host
CPU bottlenecks Memory bottlenecks

Oracle
CPU/waits

Uses ASH
and AWR

SQL Sessions

7-13 Copyright © 2006, Oracle. All rights reserved.


Performance Pages For Reactive Tuning

Home

ASH Run
Performance
Report ADDM

Active sessions
waiting

SQL
Histograms
details

7-14 Copyright © 2006, Oracle. All rights reserved.


Database Home Page

7-15 Copyright © 2006, Oracle. All rights reserved.


Database Performance Page

7-16 Copyright © 2006, Oracle. All rights reserved.


Active Sessions Waiting Pages

7-18 Copyright © 2006, Oracle. All rights reserved.


SQL Details

7-20 Copyright © 2006, Oracle. All rights reserved.


Historical Data View

7-21 Copyright © 2006, Oracle. All rights reserved.


Diagnosis of Hung or
Extremely Slow Databases

• New functionality for problem analysis when the


database is performing very slowly, or is hung:
– Direct access to SGA for performance monitoring
(memory access mode)
V$SESSION
V$SESSION_WAIT
V$SYSTEM_EVENT
V$SYSSTAT
– Hang analysis using Enterprise Manager
• Also supported for Oracle9i databases

7-22 Copyright © 2006, Oracle. All rights reserved.


Using Memory Access Mode

7-23 Copyright © 2006, Oracle. All rights reserved.


Using the Hang Analysis Page

7-24 Copyright © 2006, Oracle. All rights reserved.


Practice Overview:
Reactive Tuning

This practice covers the following topics:


• Use Enterprise Manager performance pages to
identify or eliminate OS issues
• Use Enterprise Manager performance pages to
identify database performance issues in an
application workload

7-26 Copyright © 2006, Oracle. All rights reserved.


Summary

In this lesson, you should have learned how to:


• Use Enterprise Manager pages to identify
performance issues
• Eliminate and identify operating system issues

7-27 Copyright © 2006, Oracle. All rights reserved.

You might also like