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

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.