Search notes:

Oracle: alert log

The alert log stores database messages (also error messages) in chronological order. Messages that go to the alert log file include
The alert log is stored in the Automatic Diagnostic Repository (ADR).

Locating the alert log

The alert log file is found in the directory that is returned with the following query:
select
   value
from
   v$diag_info
where
   name = 'Diag Trace';

Showing the contents of the alert log

ADRCI

With ADRCI, the content of the alert log file is opened in an editor:
$ adrci
…
adrci> show alert
In order to change the editor in which the alert log is displayed, set editor must be used:
adrci> set editor gvim

Via X$DBGALERTEXT

The content of the alert log file is also exposed in the x$dbgalertext view.

Writing to the alert log

It is possible to write a message to the alert log with the dbms_system.ksdwrt() function

See also

The attention log which was introduced with 21c.
Event 10035 write SQL parse failures to the alert log.

Index