Change the Oracle database connection Port
The default database listening and connection ports of Oracle databases are 1521, but sometimes the default ports need to be changed in the project. In this way, the customer requirements are usually based on security considerations. taking Oracle 11g as an example, it takes the following steps to change the Listener Port:
1. view the current Listener status through the command line
C: \> lsnrctl status
After the Listener is executed, the displayed content will tell you that the current Listener is associated with those database instances.
2. Run the command to stop the Oracle Listener service.
C: \> lsnrctl stop
Run this command to stop the Oracle listening service,
3. Open the listener. ora and tnsnames. ora files to modify the port number.
Add SID registration content as follows:
SID_LIST_listener_name =
(SID_LIST =
(SID_DESC =
(GLOBAL_DBNAME = global_database_name)
(SID_NAME = sid)
(ORACLE_HOME = oracle_home ))
(SID_DESC = ...))
Two file folders: $ ORACLE_HOME/network/admin/
Save the modified File
4. Execute
Lsnrctl start
You will find that the Oracle listening service is restarted and associated with the startup of your specified SID Service
5. Verify connection
C: \> sqlplus/nolog
SQL: \> connect system/manager @ SID
If a successful connection is displayed, the port is successfully changed.
Note:
By default, the listener. ora file does not contain the static registration service Section.
Be sure to manually add it and make sure the format is correct. Otherwise, the following error will be returned:
TNS-12560: TNS: protocol adapter error
TNS-00530: Protocol adapter error
Check the modified file !!
--------------------------------------------------------------------------------
Installing Oracle 12C in Linux-6-64
Install Oracle 11gR2 (x64) in CentOS 6.4)
Steps for installing Oracle 11gR2 in vmwarevm
Install Oracle 11g XE R2 In Debian
--------------------------------------------------------------------------------