How To generate the ADDM reports in Oracle database ?

 The contents are of my own testing and deployments. Not guaranteed that these might work in your environment. Please test before usage.

In this blog, I will teach you how to generate ADDM reports in the Oracle database.

What is an ADDM report?

ADDM is nothing but an Automatic database diagnostic Monitoring report, This report provides more information about database performance-related issues, and ADDM recommends multiple solutions for the DBA to choose from which include database configuration, schema level, and application level.


How to run the ADDM report in the Oracle database?

Connect the server and Start the DB if down, 


Then run the below command in SQL utility.


SQL>@$ORACLE_HOME/rdbms/admin/addmrpt.sql


Demo:

SQL> select name,open_mode from v$database;


NAME      OPEN_MODE

--------- --------------------

PROD      READ WRITE


SQL> @$ORACLE_HOME/rdbms/admin/addmrpt.sql

Current Instance

~~~~~~~~~~~~~~~~

   DB Id    DB Name      Inst Num Instance

----------- ------------ -------- ------------

  544189800 PROD                1 prod


Instances in this Workload Repository schema

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

   DB Id     Inst Num DB Name      Instance     Host

------------ -------- ------------ ------------ ------------

* 544189800         1 PROD         prod         oracle.local

                                                domain

Using  544189800 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.


Listing the last 3 days of Completed Snapshots

Specify the Begin and End Snapshot Ids

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Enter value for begin_snap: 53

Begin Snapshot Id specified: 53


Enter value for end_snap: 54

End   Snapshot Id specified: 54


Specify the Report Name

~~~~~~~~~~~~~~~~~~~~~~~

The default report file name is addmrpt_1_53_54.txt.  To use this name,

press <return> to continue, otherwise enter an alternative.

Enter value for report_name: ramesh_addm.html

Using the report name ramesh_addm.html



Running the ADDM analysis on the specified pair of snapshots ...



Generating the ADDM report for this analysis ...



          ADDM Report for Task 'TASK_151'

          -------------------------------


Analysis Period

---------------

AWR snapshot range from 53 to 54.

Time period starts at 14-APR-23 10.37.29 PM

Time period ends at 14-APR-23 11.30.06 PM


Analysis Target

---------------

Database 'PROD' with DB ID 544189800.

Database version 12.1.0.2.0.

ADDM performed an analysis of instance prod, numbered 1 and hosted at

oracle.localdomain.


Activity During the Analysis Period

-----------------------------------

Total database time was 1 seconds.

The average number of active sessions was 0.



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


There are no findings to report.


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


          Additional Information

          ----------------------


Miscellaneous Information

-------------------------

There was no significant database activity to run the ADDM.


The database's maintenance windows were active during 100% of the analysis

period.



End of Report

Report written to ramesh_addm.html

SQL> exit

Disconnected from Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production

With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options

[oracle@oracle ~]$ ll

total 12

drwxr-x---. 3 oracle oinstall   17 Mar 24 21:52 cfgtoollogs

drwxr-xr-x. 2 oracle oinstall    6 Mar 24 20:47 Desktop

drwxr-xr-x. 2 oracle oinstall    6 Mar 24 20:47 Documents

drwxr-xr-x. 2 oracle oinstall    6 Mar 24 20:47 Downloads

drwxr-xr-x. 2 oracle oinstall    6 Mar 24 20:47 Music

-rw-------. 1 oracle oinstall   94 Apr 12 12:18 nohup.out

drwxr-xr-x. 2 oracle oinstall 4096 Mar 24 21:42 Pictures

drwxr-xr-x. 2 oracle oinstall    6 Mar 24 20:47 Public

-rw-r--r--. 1 oracle oinstall 1198 Apr 16 19:10 ramesh_addm.html

drwxr-xr-x. 2 oracle oinstall    6 Mar 24 20:47 Templates

drwxr-xr-x. 2 oracle oinstall    6 Mar 24 20:47 Videos

[oracle@oracle ~]$



                                        Thanks for your time!














0 Comments

DELETE Statement in ORACLE DB— Step by Step Internal Flow with classroom example.

Imagine your Oracle database like a school, and you’re Teacher decides to remove a student (row) from the classroom(table). Let’s see how the journey works step by step: 1)Classroom = Oracle Table 2)Students = Rows (Records) 3)Class Teacher = Oracle Server Process 4)Attendance Register = Data Dictionary User fires DELETE statement: DELETE FROM students WHERE grade = 'D'; Internal Processing Steps: Client Process Sends DELETE Statement to Server Process The teacher receives a request to remove a student from the classroom. Syntax Check (Parsing) The teacher checks if the request is grammatically correct — proper command, keywords, and a semicolon. Semantic Check Teacher verifies if the classroom exists and whether the condition (like grade = 'D') makes sense. Object Resolution Teacher confirms that the ‘students’ classroom (table) exists in the school records (data dictionary). Optimization Decides the fastest way to find those students — by roll number, grade, or al...