Listener Log file location in Oracle

I will explain Listener Log file location in Oracle in this post.

 

 

Listener Log file location in Oracle

Listener log file locations are very important for us. If you want to learn where listener log file location is, execute the lsnrctl status command as follows.

 

[[email protected] admin]$ lsnrctl status

LSNRCTL for Linux: Version 12.1.0.2.0 - Production on 16-JUL-2021 14:54:57

Copyright (c) 1991, 2014, Oracle. All rights reserved.

Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 12.1.0.2.0 - Production
Start Date 16-JUL-2021 14:54:41
Uptime 0 days 0 hr. 0 min. 15 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/12.1.0.2/grid/network/admin/listener.ora
Listener Log File /u01/app/oracle/diag/tnslsnr/msdbdbadm01/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=LISTENER)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.3.16)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.2.9)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=msdbdbadm01.deveci.local)(PORT=5500))(Security=(my_wallet_directory=/u01/app/oracle/product/12.1.0.2/dbhome_1/admin/msdb/xdb_wallet))(Presentation=HTTP)(Session=RAW))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=msdbdbadm01.deveci.local)(PORT=5501))(Security=(my_wallet_directory=/u01/app/oracle/product/12.1.0.2/dbhome_1/admin/REPDB/xdb_wallet))(Presentation=HTTP)(Session=RAW))
Services Summary...
Service "FLEXDB" has 1 instance(s).
Instance "FLEXDB1", status READY, has 1 handler(s) for this service...
Service "FLEXDBXDB" has 1 instance(s).
Instance "FLEXDB1", status READY, has 1 handler(s) for this service...
Service "REPDB" has 1 instance(s).
Instance "REPDB1", status READY, has 1 handler(s) for this service...
Service "REPDBXDB" has 1 instance(s).
Instance "REPDB1", status READY, has 1 handler(s) for this service...
Service "msdb" has 1 instance(s).
Instance "msdb1", status READY, has 1 handler(s) for this service...
Service "msdbXDB" has 1 instance(s).
Instance "msdb1", status READY, has 1 handler(s) for this service...
The command completed successfully
[[email protected] admin]$

 

 

 

 

 

 

 

I have marked the listener log file and parameter file locations above with RED and BLUE Color.

Listener Parameter File /u01/app/12.1.0.2/grid/network/admin/listener.ora
Listener Log File /u01/app/oracle/diag/tnslsnr/msdbdbadm01/listener/alert/log.xml

 

When i go to /u01/app/oracle/diag/tnslsnr/msdbdbadm01/listener/alert directory, you can see the Listener log files ( Archived ) as follows.

 

-rw-r----- 1 oracle oinstall 11M Jun 11 10:14 log_409.xml
-rw-r----- 1 oracle oinstall 11M Jun 11 14:08 log_410.xml
-rw-r----- 1 oracle oinstall 11M Jun 12 20:22 log_411.xml
-rw-r----- 1 oracle oinstall 5.0M Jul 16 15:07 log.xml
[[email protected] alert]$ 
[[email protected] alert]$ pwd
/u01/app/oracle/diag/tnslsnr/msdbdbadm01/listener/alert
[[email protected] alert]$

 

 

 

If you want to review the log file, you can display it with tail command as follows.

[[email protected] alert]$ tail -10f log.xml 
host_addr='192.168.3.16'>
<txt>16-JUL-2021 15:14:01 * (CONNECT_DATA=(SERVICE_NAME=msdb)(CID=(PROGRAM=C:\Windows\SysWOW64\inetsrv\w3wp.exe)(HOST=WEBMIS)(USER=webmis))(SERVER=dedicated)(INSTANCE_NAME=msdb1)) * (ADDRESS=(PROTOCOL=tcp)(HOST=192.168.8.60)(PORT=60861)) * establish * msdb * 0
</txt>
</msg>
<msg time='2021-07-16T15:14:02.106+03:00' org_id='oracle' comp_id='tnslsnr'
type='UNKNOWN' level='16' host_id='msdbdbadm01.deveci.local'
host_addr='192.168.3.16'>
<txt>16-JUL-2021 15:14:02 * (CONNECT_DATA=(CID=(PROGRAM=)(HOST=__jdbc__)(USER=))(SERVICE_NAME=msdb)(CID=(PROGRAM=)(HOST=__jdbc__)(USER=))) * (ADDRESS=(PROTOCOL=tcp)(HOST=192.168.8.54)(PORT=50398)) * establish * msdb * 0
</txt>
</msg>
^C
[[email protected] alert]$ 
[[email protected] alert]$ 
[[email protected] alert]$

 

 

Listener Parameter File Location

Listener parameter files is located under $ORACLE_HOME/network/admin directory as follows.

If you are using the Oracle RAC, Cluster manages the Listener, and you can also use the static listener.

 

[[email protected] admin]$ cd $ORACLE_HOME/network/admin
[[email protected] admin]$ 
[[email protected] admin]$ pwd
/u01/app/12.1.0.2/grid/network/admin
[[email protected] admin]$ 
[[email protected] admin]$ cat listener.ora
MGMTLSNR=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=IPC)(KEY=MGMTLSNR)))) # line added by Agent
# listener.ora Network Configuration File: /u01/app/12.1.0.2/grid/network/admin/listener.ora
# Generated by Oracle configuration tools.

ENABLE_GLOBAL_DYNAMIC_ENDPOINT_LISTENER_SCAN3 = ON

ENABLE_GLOBAL_DYNAMIC_ENDPOINT_LISTENER_SCAN2 = ON

ENABLE_GLOBAL_DYNAMIC_ENDPOINT_LISTENER_SCAN1 = ON

VALID_NODE_CHECKING_REGISTRATION_LISTENER_SCAN3=OFF # line added by Agent

VALID_NODE_CHECKING_REGISTRATION_LISTENER_SCAN2=OFF # line added by Agent

VALID_NODE_CHECKING_REGISTRATION_LISTENER_SCAN1=OFF # line added by Agent

VALID_NODE_CHECKING_REGISTRATION_LISTENER = SUBNET

LISTENER =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = LISTENER))
)
)

ENABLE_GLOBAL_DYNAMIC_ENDPOINT_LISTENER = ON

LISTENER_SCAN3 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = LISTENER_SCAN3))
)
)

LISTENER_SCAN2 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = LISTENER_SCAN2))
)
)

LISTENER_SCAN1 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = LISTENER_SCAN1))
)
)

ENABLE_GLOBAL_DYNAMIC_ENDPOINT_MGMTLSNR=ON # line added by Agent
VALID_NODE_CHECKING_REGISTRATION_MGMTLSNR=SUBNET # line added by Agent
[[email protected] admin]$

 

 

You can read the following post to learn more details about Oracle Listener.

How to set LOCAL_LISTENER using Alter System Set Command in Oracle

 

 

 

Do you want to learn Oracle Database for Beginners, then read the following articles.

Oracle Tutorial | Oracle Database Tutorials for Beginners ( Junior Oracle DBA )

 

 

 2,112 views last month,  4 views today

About Mehmet Salih Deveci

I am Founder of SysDBASoft IT and IT Tutorial and Certified Expert about Oracle & SQL Server database, Goldengate, Exadata Machine, Oracle Database Appliance administrator with 10+years experience.I have OCA, OCP, OCE RAC Expert Certificates I have worked 100+ Banking, Insurance, Finance, Telco and etc. clients as a Consultant, Insource or Outsource.I have done 200+ Operations in this clients such as Exadata Installation & PoC & Migration & Upgrade, Oracle & SQL Server Database Upgrade, Oracle RAC Installation, SQL Server AlwaysOn Installation, Database Migration, Disaster Recovery, Backup Restore, Performance Tuning, Periodic Healthchecks.I have done 2000+ Table replication with Goldengate or SQL Server Replication tool for DWH Databases in many clients.If you need Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS Consultancy and Training you can send my email adress [email protected].-                                                                                                                                                                                                                                                 -Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS ve linux Danışmanlık ve Eğitim için  [email protected] a mail atabilirsiniz.

Leave a Reply