Automatic Diagnostic Repository (ADR)

Automatic Diagnostic Repository

Oracle has decided to re-design the way where log and trace files are generated, they have made obsolete the well known following parameters:

  • background_dump_dest
  • core_dump_dest
  • user_dump_dest

Starting with 11gR1 they are introducing Automatic Diagnostic Repository (ADR) and new initialization parameter:

  • diagnostic_dest

This repository is a file repository and all files are in <diagnostic_dest>/diag/rdbms/<dbname>/<instname>. So as per my standard I would set diagnostic_dest=/ora_<sid>/dump/<sid> then the alert.log file will now be in /ora_<sid>/dump/<sid>/diag/rdbms/<sid>/<sid>/alert (db_name and sid are the same in my standards).

To see directly from Oracle where are the files you can use:

SQL> SELECT * FROM v$diag_info;
 
   INST_ID NAME                           VALUE
---------- ------------------------------ ------------------------------------------------------------
         1 Diag Enabled                   TRUE
         1 ADR Base                       /ora_oid/DUMP/oid
         1 ADR Home                       /ora_oid/DUMP/oid/diag/rdbms/oid/oid
         1 Diag Trace                     /ora_oid/DUMP/oid/diag/rdbms/oid/oid/trace
         1 Diag Alert                     /ora_oid/DUMP/oid/diag/rdbms/oid/oid/alert
         1 Diag Incident                  /ora_oid/DUMP/oid/diag/rdbms/oid/oid/incident
         1 Diag Cdump                     /ora_oid/DUMP/oid/diag/rdbms/oid/oid/cdump
         1 Health Monitor                 /ora_oid/DUMP/oid/diag/rdbms/oid/oid/hm
         1 DEFAULT Trace FILE             /ora_oid/DUMP/oid/diag/rdbms/oid/oid/trace/oid_ora_20403.trc
         1 Active Problem COUNT           0
         1 Active Incident COUNT          0
 
11 ROWS selected.

New issue you will see is that the alert.log file in now in XML format (but Oracle is not providing the associated XSL file) and it’s worth to say that it’s not really easy to dig into it… They do anyway provide a tool to do it, see next chapter.

Fortunately the alert.log is also provided the old-way in text format and you can find it at /ora_<sid>/dump/<sid>/diag/rdbms/<sid>/<sid>/trace with it’s old name i.e. alert_<sid>.log, with the associated *.trc files.

ADRCI

ADRCI stands for ADR Command Interpreter, yep another tool to display XML release of alert.log file… Nothing special to say except few commands that will be used in day-to-day activities, issue adrci with Oracle Unix account to launch it:

adrci> show alert -tail 10
adrci> show alert -tail -f
adrci> show incident
 
ADR Home = /ora_oid/dump/oid/diag/rdbms/oid/oid:
*************************************************************************
0 rows fetched
adrci> show alert -p "message_text like 'ORA-%'"

About Post Author

Share the knowledge!

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>