After installation of SAP system or in support phase, the requirement comes to change the oracle listener port number or even some time it is needed to rename the LISTENER to LISTENER_SID or something.

Lets first see how to change listener port.

To change the port you need to modify 3 files. two tnsnames.ora and one listener.ora file.

The location of tnsnames.ora will be at below two locations

  1. /sapmnt//profile/oracle/tnsnames.ora
  2. $ORACLE_HOME/network/admin/tnsnames.ora

3. $ORACLE_HOME/network/admin/listener.ora

  • Stop sap application
  • Stop listener
  • No need to stop your database.

Now you can change the port numbers in the 3 files mentioned above, The port number is marked with red line can be changed with another number which is permissible as per your scenario.

Now you can start the listener, and your database is running then you can check connectivity from your application server by

R3trans -d it should work now.

You can also do the telnet from Database server or application server to the new port, it should connect.


Change of listener port done.

Now lets move to rename the listener name itself.

If you can notice listener.ora screenshot above, you can see the name is LISTENER, which is default value.

Now you want to rename it, lets say LISTENER_ECC.

If you will execute

$ ps -ef|grep lsn

  orar q 1007798   1   0   Apr 10  –  3:57 /oracle/R  Q/112_64/bin/tnslsnr LISTENER -inherit

This will show the listener process and its Name.

1. Here you need to stop your listener

$ lsnrctl stop LISTENER

2. Now you can modify the file


As per the screenshot, you need to change LISTENER to LISTENER_ECC in listener.ora file where it is marked with red line, save it and start the new listener

$  lsnrctl start LISTENER_ECC

Then check the process name when you will do

$ ps -ef|grep lsn

orar s 1069298   1   0   Mar 29  –  4:39 /oracle/R  S/112_64/bin/tnslsnr LISTENER_ECC -inherit

Now you can see the listner is started with new name.

Wait its not done yet, when you will do R3trans -d it will not work!

You need to change the local listener inside oracle database, for that please proceed as below

Let your new listener LISTENER_ECC keep running

Start your SQL prompt with ora

SQL> show parameter local_listener

NAME                                 TYPE        VALUE

———————————— ———– ——————————

local_listener                       string

Here you need to modify the parameter “local_listener”

SQL> alter system set local_listener='(address=(protocol=tcp)(host=ara- – -dbp05)(port=1521))’;

System altered.

Note: hostname and port should be same as it is mentioned in listener.ora

SQL> alter system register;

System altered.

Now you can go and execute R3trans -d, it will be able to connect to database.

The renaming of listener is complete!

Hope this will be of help to some of us.

My other Blogs, if you have time…

How to Rename the Oracle Listener & Change Listener port for SAP

Multiple/Bulk transports with tp script for Unix (AIX, Solaris, HP-UX, Linux)


Interrelation: SAP work process, OPS$ mechanism, oracle client & oracle shadow process

Install and configure NetWeaver PI 7.3 Decentralize Adapter part-1

Install and configure NetWeaver PI 7.3 Decentralize Adapter part-2

Bye bye STRUSTSSO2: New Central Certificate Administration NW7.3

New NetWeaver Information at

Very Helpfull

User Rating: Be the first one !