Check the alert and listener log location as text and xml in Oracle

Check the alert and listener log location as text and xml in Oracle

For alert log XML file locations

SQL> SELECT name,VALUE FROM V$DIAG_INFO where name = 'Diag Alert';

NAME       VALUE
---------- -----------------------------------------
Diag Alert C:\ORACLE\diag\rdbms\xe\xe\alert

For alert log text file location

1. Find diag location
SQL> SELECT name,VALUE FROM V$DIAG_INFO where name = 'Diag Alert';

NAME       VALUE
---------- -----------------------------------------
Diag Alert C:\ORACLE\diag\rdbms\xe\xe\alert

2. For text file move to trace folder instead of alert folder.
C:\ORACLE\diag\rdbms\xe\xe\trace

Note:
For 10g or older, Check background dump parameter for alert log:

SQL> Show parameter background_dump_dest

NAME                   TYPE        VALUE
---------------------- ----------- ------------------------------
background_dump_dest   string      C:\ORACLE\DBHOMEXE\RDBMS\TRACE

For listener log files

1. Find the diag parameter location
SQL> show parameter diag

NAME              TYPE        VALUE
----------------- ----------- -------------
diagnostic_dest   string      C:\ORACLE

2. For text file:
$DIAG_LOCATION\tnslsnr\RAC1\listener\trace\listener.log

3. For XML File:
$DIAG_LOCATION\tnslsnr\RAC1\listener\alert\log.xml

Note:
You get the listener log location with lsnrctl status command

$LSNRCTL status
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=RAC1.oracle.com)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for 64-bit Windows: Version 18.0.0.0.0 - Production
Start Date                05-FEB-2020 12:57:34
Uptime                    0 days 22 hr. 30 min. 5 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   C:\Oracle\dbhomeXE\network\admin\listener.ora
Listener Log File         C:\Oracle\dbhomeXE\log\diag\tnslsnr\RAC1\listener\alert\log.xml

This entry was posted in Oracle on by .
Unknown's avatar

About SandeepSingh

Hi, I am working in IT industry with having more than 15 year of experience, worked as an Oracle DBA with a Company and handling different databases like Oracle, SQL Server , DB2 etc Worked as a Development and Database Administrator.

Leave a Reply