Oracle Database Listener an Overview

Oracle Listener

What is an Oracle Listener?

The listener is a process that runs on the database server . It receives incoming client connection requests and manages the traffic of these requests to the database server. One Listener can listen incoming Client request for more than one database.

Where is the Listener Configuration file Stored?

Oracle Listener configuration file is always located in ORACLE_HOME/network/admin Directory and named as listener.ora
where  ORACLE_HOME is the Location where you have Oracle Database binaries Installed.

How to Create Listener

Creating of Listener is really easy you just Need to put an Entry like below in your listener.ora file. If the file already does not exists just create it

Note:- use vi on Linux based Server or Notepad on Windows to edit the listener.ora file.

Sample listener.ora

        (ADDRESS = (PROTOCOL = TCP)(HOST = = 1521))

Optionally you can tell Listenr for what all database it must listen by entring the respective entries in below Format.

    (SID_DESC =
      (SID_NAME = DBNAME1)
      (ORACLE_HOME = /u01/app/oracle/product/
    (SID_DESC =
      (ORACLE_HOME =/u01/app/oracle/product/
      (SID_NAME = DBNAME2)

Oracle provides another GUI Methode to create Listener and the tool used here is called Oracle Network Configuration Assistence

on Linux based plateform you can invoke the Utility by entring below command, considering Oracle binaries are installed under /u01/app/oracle/product/

$export ORACLE_HOME==/u01/app/oracle/product/

optionally you can nevigate under $ORACLE_HOME/bin and execute netca command from there

$ cd  /u01/app/oracle/product/

If you use NETCA (recommended) Methode to create the LISTENER it will not only just create the listener but also start it.

How to Start Listener in Oracle

$export ORACLE_HOME==/u01/app/oracle/product/
$ lsnrctl start LISTENER01

How to Check the Staus of Listener in Oracle

$export ORACLE_HOME==/u01/app/oracle/product/
$ lsnrctl Status LISTENER01

Where to find the Listener Log Oracle.

$ lsnrctl status LISTENER01
LSNRCTL for Linux: Version - Production on 29-JUL-2017 15:10:56
Copyright (c) 1991, 2016, Oracle.  All rights reserved.
Alias                     LISTENER01
Version                   TNSLSNR for Linux: Version - Production
Start Date                29-JUL-2017 15:09:22
Uptime                    0 days 0 hr. 1 min. 34 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /u01/app/
Listener Log File         /u01/app/oracle/diag/tnslsnr/node2/listener01/alert/log.xml
Listening Endpoints Summary...
The listener supports no services
The command completed successfully

No comments:

Post a Comment