2

Im using oracle 12c on windows server 2016. I want to make my oracle to listen to the port 1521 to 0.0.0.0

Here is my listner.ora file.

# listener.ora Network Configuration File: C:\app\bhuvi\virtual\product\12.2.0\dbhome_2\network\admin\listener.ora
# Generated by Oracle configuration tools.

SID_LIST_ORCL_BHUVI =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = CLRExtProc)
      (ORACLE_HOME = C:\app\bhuvi\virtual\product\12.2.0\dbhome_2)
      (PROGRAM = extproc)
      (ENVS = "EXTPROC_DLLS=ONLY:C:\app\bhuvi\virtual\product\12.2.0\dbhome_2\bin\oraclr12.dll")
    )
  )

ORCL_BHUVI =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = 0.0.0.0)(PORT = 1521))
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    )
  )

You can see the HOST is 0.0.0.0, but when I start the listener, there it listening the port 1521 to localhost (my hostname is bhuvi-oracle)

C:\Windows\system32>lsnrctl status

LSNRCTL for 64-bit Windows: Version 12.2.0.1.0 - Production on 18-APR-2020 17:29:19

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

Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for 64-bit Windows: Version 12.2.0.1.0 - Production
Start Date                18-APR-2020 17:29:12
Uptime                    0 days 0 hr. 0 min. 9 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   C:\app\bhuvi\virtual\product\12.2.0\dbhome_2\network\admin\listener.ora
Listener Log File         C:\app\bhuvi\virtual\diag\tnslsnr\bhuvi-oracle\listener\alert\log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=bhuvi-oracle)(PORT=1521)))
The listener supports no services
The command completed successfully

Can somebody help me to solve this issue?

4
  • It can be done but instance will be isolated no users cannot connect through network unless they have direct access to host server or via ssh.Why 0.0,0.0?.
    – user168186
    Apr 19, 2020 at 0:31
  • What exactly is the issue you are trying to solve with this "0.0.0.0" configuration?
    – pmdba
    Apr 19, 2020 at 14:44
  • I have some applications which are connecting from outside. Im not able to access it.
    – TheDataGuy
    Apr 20, 2020 at 7:08
  • Take a look at superuser.com/questions/949428/… -- Sounds like you may not be clear on what the HOST = parm for the TNS Listener is for. May 18, 2020 at 16:53

1 Answer 1

3

You have to change the files at the following locations:

  1. $ORACLE_HOME/network/admin/listener.ora
  2. $ORACLE_HOME/network/admin/tnsnames.ora

On both these files you have to update the HOST attribute to 0.0.0.0

Restart both the Oracle database and listener after making these changes.

Hope this helps anyone else stuck on this issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.