Search This Blog

Showing posts with label STATSPACK. Show all posts
Showing posts with label STATSPACK. Show all posts

Tuesday, July 26, 2011

Load Profile

Tips:
Oracle Certification - Tips

DBA Preparation - Tips

Practical DBA - Tips







Load Profile


1. Redo size: The amount of redo generated during this report.

2. Logical Reads: Calculated as (Consistent Gets XE "Consistent Gets" + DB Block Gets XE "DB Block Gets" = Logical Reads).
Block changes: The number of blocks modified during the sample interval.
Physical Reads: The number of requests for a block that caused a physical I/O operation.

3. Physical Writes: Number of physical writes performed.
User Calls: Number of user queries generated.

4. Parses: The total of all parses; both hard and soft.

5. Hard Parses: The parses requiring a completely new parse of the SQL statement. These consume both latches and shared pool area.

6. Soft Parses: Soft parses are not listed but derived by subtracting the hard parses from parses. A soft parse reuses a previous hard parse; hence it consumes far fewer resources.

7. Sorts, Logons, Executes and Transactions: All self-explanatory.


The following information is also available in the workload section:




1. % Blocks changed per Read:

The % Blocks changed per Read statistic indicates all blocks are retrieved for update.
Blocks Changed per Read % = (Block Changes + 100/ Logical Reads)

2. Recursive Call %:

Sometimes, in order to execute a SQL statement issued by a user, Oracle must issue additional statements. Such statements are called recursive calls or recursive SQL statements. For example, if you insert a row into a table that does not have enough space to hold that row, then Oracle makes recursive calls to allocate the space dynamically. Recursive calls are also generated when data dictionary information is not available in the data dictionary cache and must be retrieved from disk.

3. Rollback per transaction %:

4. Rows per Sort


Sunday, October 21, 2007

AWR Report/Snapshot




My Signature Article



Tips:
Oracle Certification - Tips

DBA Preparation - Tips

Practical DBA - Tips




Prior Oracle 10g we use STATSPACK report to analyze instance health for performance. but now in 10g we use AWR(automatic workload repository) report to analyze Oracle Database health.


How to generate AWR report ?


It is very easy to generate AWR report in Oracle 10g.

We have to run just one sql script to generate AWR report.


There is TWO sql script to create AWR report.
1. awrrpt.sql
If we have only One Oracle Database then run awrrpt.sql sql script.

2. awrrpti.sql
If we have more than One Oracle Instance (Like RAC) then run awrrpti.sql script so that we can particular instance for awr report creation.



Location of AWR report sql script


$ORACLE_HOME/rdbms/admin


Example Of AWR report


AWR report Example


What is default interval period between two awr report ?


AWR report generate automatically for database every 1 hr interval period.
But Recommanded is 15 Minutes is enough in two snapshot for better performance bottleneck.


How to Manage & change interval period for awr report ?


There is two to modify or changes in AWR report.
1. Manually ---> through DBMS_WORKLOAD_REPOSITORY plsql package

2. GUI ----> OEM (Oracle Enterprise Manager)
Login to OEM ---> Administration Tag ----> Workload Section --->AUTOMATIC WORKLOAD REPOSITORY


How to Interpreting with AWR report ?


Below is Main Section in AWR report for concern.

Load Profile

In this section we know about Logical Read, Physical Read, Soft Parse, Hard Parse

Instance Efficiency Percentages

Many Oracle Guru's is not recommended to trust on Instance percentage ratio. becuase suppose if your instance percentage show BUFFER CAHCE HIT RATIO is 100% it is not sign for your database is very fast and running smootly.

Top 5 Timed Events

It is very important section in AWR report.
through this we can know most five wait event is effecting database performance.

Oracle Wait Event


SQL Statistics

It this section we will know about Execution time, cpu used, logical & physical read for top most sql statement.


Advisory Statistics

In this section we will get advice for PGA, BUFFER CACHE, SHARED POOL, JAVA POOL size for better performance.


Visit following link for reference interpreting awr report

Reference I

Monday, May 7, 2007

STATSPACK

Below step for generate statspack Report


1. User must have SYSDBA privs


set ORACLE_SID=orcl
sqlplus sys/pwd as sysdba



2.You should create SEPRATE TABLESPACE for statspack report.



create tablespace PERFSTAT
datafile 'c:\perf01.dbf' size 100m
autoextend on
segment management auto;



We should generate STATSPACK report DURING PEAK TIME
run SPCREATE.SQL script
Located : $ORACLE_HOME\rdbms\admin\spcreate.sql



conn sys as sysdba
@$ORACLE_HOME\rdbms\admin\spcreate.sql



4.connect with PERFSTAT user
perfstat user create automatically when we run SPCREATE.SQL script


conn perfstat/password



5.run STATSPACK.SNAP procedure




exec statspack.snap;



Note: After 15 minutes run again STATSPACK.SNAP procedure



6.run SPREPORT for generate statspack report in text format.



@$ORACLE_HOME\rdbms\admin\spreport.sql



7.connect with SYSDBA privs user ( sys user)
and execute SPDROP.SQL script for drop PERFSTAT user and all related tables



conn sys as sysdba
@$ORACLE_HOME\rdbms\admin\spdrop.sql



8.DROP TABLESPACE use for STATSPACK REPORT



conn sys as sysdba
drop tablespace [TABLESPACE NAME]
including contents and datafiles



Note: analyze your report


http://www.statspackanalyzer.com/analyze.asp
http://www.oraperf.com