I must thank my fellow DBA Franky Weber Faust for his publication in his blog.
We know NetCA  Oracle command line for configuring the Oracle listener. NetCA stands for (Network Configuration Assistant). NetCA is used as a configuration assistant launched by the OUI at install time. It is more suitable for a batch mode for silent installations.

I will show how to create the Listener with NETCA in text mode using a response file. Before creating the database I like to create the Listener because if we are going to configure the Enterprise Manager the Listener must be previously created and running.

Listener creation process using NETCA via response file

Adjust the environment variables:

[oracle@oracle-srv netca]$ . oraenv
ORACLE_SID = [cdb] ? cdb2
ORACLE_HOME = [/home/oracle] ? /u01/app/oracle/product/12.2.0.1/db_1
The Oracle base remains unchanged with value /u01/app/oracle

Run NETCA by passing the response file. The response file default that comes with the installation is enough to upload a Listener, if necessary you can adjust it as you want.

[oracle@oracle-srv netca]$ netca -silent -responsefile /u01/app/oracle/product/12.2.0.1/db_1/assistants/netca/netca.rsp
Parsing command line arguments:
Parameter "silent" = true
Parameter "responsefile" = /u01/app/oracle/product/12.2.0.1/db_1/assistants/netca/netca.rsp
Done parsing command line arguments.
Oracle Net Services Configuration:
Profile configuration complete.
Oracle Net Listener Startup:
Running Listener Control:
/u01/app/oracle/product/12.2.0.1/db_1/bin/lsnrctl start LISTENER
Listener Control complete.
Listener started successfully.
Listener configuration complete.
Oracle Net Services configuration successful. The exit code is 0

Verify that the Listener is running:

[oracle@oracle-srv ~]$ lsnrctl status LISTENER

LSNRCTL for Linux: Version 12.2.0.1.0 - Production on 10-JUN-2017 20:48:02

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

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=oracle-srv.localdomain)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 12.2.0.1.0 - Production
Start Date 10-JUN-2017 19:48:06
Uptime 0 days 0 hr. 59 min. 56 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/oracle/product/12.2.0.1/db_1/network/admin/listener.ora
Listener Log File /u01/app/oracle/diag/tnslsnr/oracle-srv/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=oracle-srv.localdomain)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
The listener supports no services
The command completed successfully

About The Author

Comments

Leave a Reply

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