Change the Oracle database connection Port

Source: Internet
Author: User

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

--------------------------------------------------------------------------------

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.