Table of Contents
AWR report types
@?/rdbms/admin/awrrpt.sql -- basic AWR report @?/rdbms/admin/awrsqrpt.sql -- Standard SQL statement Report @?/rdbms/admin/awrddrpt.sql -- Period diff on current instance @?/rdbms/admin/awrrpti.sql -- Workload Repository Report Instance (RAC) @?/rdbms/admin/awrgrpt.sql -- AWR Global Report (RAC) @?/rdbms/admin/awrgdrpt.sql -- AWR Global Diff Report (RAC) @?/rdbms/admin/awrinfo.sql -- Script to output general AWR information
Create an AWR report for a certain test case and display it with firefox
Create an AWR snapshot ,run your test case and after that create a 2nd AWR snapshot EXECUTE dbms_workload_repository.create_snapshot(); --> run test case: [oracle@grac41 JDBC]$ java UCPDemo 1000 EXECUTE dbms_workload_repository.create_snapshot(); Create an AWR report SQL> @?/rdbms/admin/awrgrpt.sql [ @?/rdbms/admin/awrddrpt.sql Current Instance ~~~~~~~~~~~~~~~~ DB Id DB Name Inst Num Instance ----------- ------------event_histogram.sql -------- ------------ 794109772 GRAC4 1 grac41 Specify the Report Type ~~~~~~~~~~~~~~~~~~~~~~~ Would you like an HTML report, or a plain text report? Enter 'html' for an HTML report, or 'text' for plain text Defaults to 'html' Enter value for report_type: Type Specified: html Instances in this Workload Repository schema ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ DB Id Inst Num DB Name Instance Host ------------ -------- ------------ ------------ ------------ 794109772 3 GRAC4 grac43 grac43.example.com * 794109772 1 GRAC4 grac41 grac41.example.com 794109772 2 GRAC4 grac42 grac42.example.com Using 794109772 for database Id Using 1 for instance number Specify the number of days of snapshots to choose from ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Entering the number of days (n) will result in the most recent (n) days of snapshots being listed. Pressing <return> without specifying a number lists all completed snapshots. Enter value for num_days: 1 Listing the last day's Completed Snapshots Snap Instance DB Name Snap Id Snap Started Level ------------ ------------ --------- ------------------ ----- grac41 GRAC4 358 29 Oct 2013 11:00 1 .. 364 29 Oct 2013 15:04 1 365 29 Oct 2013 15:16 1 Specify the Begin and End Snapshot Ids ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Enter value for begin_snap: 364 Begin Snapshot Id specified: 364 Enter value for end_snap: 365 End Snapshot Id specified: 365 Specify the Report Name ~~~~~~~~~~~~~~~~~~~~~~~ The default report file name is awrrpt_1_364_365.html. To use this name, press <return> to continue, otherwise enter an alternative. Display the report with firefox $ firefox awrrpt_1_364_365.html
Nice Article.