Oracle Configuration Management

Source: Internet
Author: User

First,Oracle Client-to-server communication mechanism

after the Oracle product installation is complete, both the server and the client need network configuration to enable network connectivity, server-side configuration listeners, and the client to configure the network service name.

1. Oracle Net protocol

Oracle NET protocol enables client-to-server connectivity and data transfer. Oracle Net is a software layer that resides both on the server side and on the client, which encapsulates TCP/IPand is responsible for establishing a connection to the database server that maintains the client application. There is a protocol that will have a corresponding port, so Oracle NET has a default listening port of 1521.

.

the request made by the client is first transformed by the Oracle Net protocol into the information that can be transmitted over the network, and the request is transmitted to the database server side through the TCP/IP Network, and the server receives the client request.   Oracle Net Protocol transformation, which translates requests into databases to interpret local instructions for execution, executes on the server side, and passes the results through TCP/IP and Oracle NET protocol is transmitted to the client display.

2, the client and the server side of the connection process

The Oracle server receives a connection request from the client through a component namedOracle Net Listener, listening to a background process on the server side. The client connection request that is sent is first listened to by the server's listener and is handed to the corresponding DB instance to establish a client-server connection. After the connection is established, the client and the server can communicate directly without the need for listeners to participate. To enable listeners to listen to customer requests, the listener needs to be configured.

The Oracle Network service name is an identifier that represents the configuration information for the client to connect to the server.

The client-to-server connection process is as follows:

1) There is a resident listener on the server side that listens for connection requests made by the client.

2) users use the client (Enterprise Manager or SQL tools), enter the user name, password, and network service name, or enter a similar "CONNECT username" on the SQL command line /[email protected]_service_name"request.

3) The client views the Network service profile Tnsnames.ora file and maps the network service name to The connection descriptor that contains the Oracle server address, listening port, and global database name.

4) The client locates the listener based on the connection descriptor and passes the network connection information to the listener.

5) The Listener queries the listener configuration file Listener.ora tofind out which server to connect to.

6) the client and the server begin to communicate.

3. The tools for Configuring and managing Oracle network configurations are common in the following categories:

1) netca Way

Viewing a listening file

Open a new listener

View listener Status

2) netmgr Way

Add listeners to

3) Command mode

Modify Vim/opt/oracle/product/11.2/db_1/network/admin/listener.ora

Add a new listener with the following code:



Open a new listener



the code in the red box above the listener supports no services shows that no service is registered to the listener, which is related to the boot sequence of the listener and DB instance.

WORKAROUND: Listen for startup and the order in which the DB instance starts

based on the previous knowledge, when you start the database instance, the listener is started, and when you connect to the database, only both of theseare available for Oracle to provide services outside.

The sequence of monitoring and instance initiation will have an impact on the coordination of work between the two, as follows:

start the listener first, then start the instance: At this point the remote client connection instance is normal, there is no problem because the listener starts first, when the instance is started the background process Pmon will listen to the registration server, and when the user requests the service, the coordination of the two is ready.

Start the instance first, then start listening: If the listener has just started, the user immediately connects to the instance and may report the "listener is currently unable to recognize the service requested by the connection descriptor" because Pmon has not yet been able to register the instance service with the listener. But this problem will only exist for a short period of time, then the connection will not have a problem, why wait a while? Because Pmon every once in a while will see the service need to listen to register, at this time if the monitoring has been started,pmon can register successfully, the coordination of the two work is ready.

is there a way to solve this problem within a short period of time? The answer is certain. is to static registration, the service description of the instance is added to the Listener.ora, so as long as the start of monitoring, the corresponding service in the listening register. This is as long as the instance starts to complete properly, it can provide the server externally. Add the following code in the listener.ora code.

4, the client connection

clients connecting to the database server must know some information, such as the host name or IP address of the database server , the communication protocol used, the port number, and the corresponding database service name, which need to be set on the client

1) installing the Oracle client software on win7

Double-click the second file to install

The Oracle folder will begenerated under the C: Disk When the installation is complete :

2) Locate the C:\oracle\product\11.2.0\client_lite\network\admin\tnsnames.ora file, and modify the results as follows:

3) Note: You need to add parsing in the hosts file

4) Open the named line on the Win7 client and execute the command connection

has been remotely connected to an Oracle server


Oracle Configuration Management

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.