How Oracle Configures multiple databases

Source: Internet
Author: User
Tags port number oracle database

Oracle can be equipped with more than one database, and only need to open a listener on it, for multiple databases as long as the appropriate service name can be configured to connect.

I'm using Oracle 8.1.7 Enterprise edition,os is Windows Server, and I've illustrated my configuration process and situation and discussed it with you.

The first step: using NET8 Configuration Assistant tool to configure the listener, always point to the next step, the final completion can be! The listening address is usually set to the default of 1521.

You can also use the Net8 Assistant tool to verify or configure the listener, as shown in the following figure, which allows you to configure the host and port.

Step two: Use the NET8 Assistant tool to configure the naming service, as shown in the following figure:

Note The service name is the database name, host name and port number must be the same as the listener!

Test, connection successful, ok!

Well, then with the second library service name, the following figure:

Note that the service name should correspond to the second database name!

Then test the connection to the second library, connect successfully, ok!

Finally, there are a few points to note:

1. For the general if there are multiple applications with Oracle database, generally only need to build a database on it, for different applications to set up different users (different table space) on it.

2. If multiple applications have different character sets, such as both BIG5 and GB2312, it is generally necessary to consider configuring multiple servers, or setting up multiple databases, or converting to character sets such as UTF-8.

3. If you need to install multiple versions of Oracle, such as installing oracle9i and Oracle8.1.7 at the same time, you need to configure your own listening ports, environment variables have nothing to configure, will not conflict; The registry is placed in the Hkey_local_ Machinesoftwareoracle, but will be divided into home0~home ... Different keys are stored, so there is no conflict.

4. Configuring naming services and listeners can also directly edit the following 2 files:

Listener: $ORACLE _home$ Etworkadminlistener.ora, general documents as follows:

# LISTENER. ORA Network Configuration file:d:databaseoracle81 Etworkadminlistener.ora

# Generated by Oracle configuration tools.

LISTENER =

(Description_list =

(DESCRIPTION =

(Address_list =

(address = (PROTOCOL = TCP) (HOST = HARRY) (PORT = 1521))

)

)

)

Sid_list_listener =

(Sid_list =

(Sid_desc =

(Sid_name = Plsextproc)

(Oracle_home = d:databaseoracle81)

(program = Extproc)

)

(Sid_desc =

(Global_dbname = Orasun)

(Oracle_home = d:databaseoracle81)

(Sid_name = Orasun)

)

(Sid_desc =

(Global_dbname = ORAGCE)

(Oracle_home = d:databaseoracle81)

(Sid_name = ORAGCE)

)

)

Service Name: $ORACLE _home$ etworkadmin Nsnames.ora, general documents as follows:

# TNSNAMES. ORA Network Configuration file:d:databaseoracle81networkadmin Nsnames.ora

# Generated by Oracle configuration tools.

Smest =

(DESCRIPTION =

(Address_list =

(address = (PROTOCOL = TCP) (HOST = 127.0.0.1) (PORT = 1521))

)

(Connect_data =

(service_name = ORAGCE)

)

)

Smedi =

(DESCRIPTION =

(Address_list =

(address = (PROTOCOL = TCP) (HOST = 127.0.0.1) (PORT = 1521))

)

(Connect_data =

(service_name = Orasun)

)

)

Inst1_http =

(DESCRIPTION =

(Address_list =

(address = (PROTOCOL = TCP) (HOST = 127.0.0.1) (PORT = 1521))

)

(Connect_data =

(SERVER = SHARED)

(service_name = ORAGCE)

(presentation = http://admin)

)

)

Extproc_connection_data =

(DESCRIPTION =

(Address_list =

(address = (PROTOCOL = IPC) (KEY = EXTPROC0))

)

(Connect_data =

(SID = Plsextproc)

(presentation = RO)

)

)

These 2 files have a corresponding sample file under $oracle_home$ etworkadminsample, which can be referenced.

After the listener configuration is modified, the service that needs to restart the listener!!!

To add that when multiple listeners are configured or one listener listens to multiple databases, the listener needs to configure the database service.

As shown in the figure, a listener listens on multiple databases, the following configuration, the database name and the SID are Orasun and ORAGCE, the same with multiple listeners listening to a database (respectively provided to the intranet and extranet), if you encounter connection problems, please check the database configuration this one, Of course, if the file directly to configure the configuration is very simple, you can do it, you can also compare to the configuration file I gave earlier look.

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.