Understanding of server_name and SID Concepts in Oracle

Source: Internet
Author: User

The "preface" is explained in the blog post:

This article will introduce the concept of server_name and instance name SID in Oracle by personal tone, and under the current time point "May 22, 2017 ", the level of technology is limited, there may be a lot of knowledge understanding is not deep or comprehensive, We would like to point out the issue of common communication, in the follow-up work and learning, such as found in this article and the actual situation deviation, will improve the content of this blog post.



This article refers to a reference link:

1, http://blog.csdn.net/luman1991/article/details/56286371

2, http://blog.csdn.net/yaksok/article/details/52130228



Body:


The server_name parameter was introduced by Oracle8i. Before 8i, a SID was used to represent an instance of the identity database, but in Oracle's parallel environment, a database corresponds to multiple instances, which requires multiple network service names and is cumbersome to set up. In order to facilitate the setting in the parallel environment, the SERVICE_NAME parameter is introduced, which corresponds to a database, not an instance, and there are many other benefits to this parameter. The default value for this parameter is db_name. Db_domain is equal to Global_name. A database can correspond to multiple service_name for a more flexible configuration. This parameter is not directly related to the SID, that is, the service name must be the same as the SID, and the SID is the name of the DB instance, each of which is different.


Case Analysis:


First, the introduction of relations:

Server = Company

Database = Operations Support Department (the database is divided into single-machine and cluster environment, that is, the number of departments of the relationship)

DB cluster environment = Operations Support Department (assuming the department has a small Li, Mei two employees, corresponding SID1,SID2)

Database connection request = Company employee or other department request operation and maintenance Department to provide technical support

Database Server = The server that is hosting the database, that is, the company that owns the active operations department, and of course the server, in addition to loading the database, I can also install other software to provide other services


Second, the work process:

1, Lao Wang is a research and development department of an employee, in the connection database discovery can not connect, so in the company internal communication platform sent a request, request operation and maintenance department to see if the database service is abnormal.

2) The operation and maintenance of Xiao Li accepted the problem, that is, Xiao Li to the old king to provide the service, and finally successfully solve the problem

3) After a week, Lao Wang found that the database connection problems, but also in the company internal communication platform sent a request, the operation and maintenance department to check whether the database service is abnormal.

4) The operation and maintenance of Xiao Mei accepted the problem, that is, Xiao Mei to Lao Wang to provide this service, and finally successfully solve the problem


Third, case analysis:

1, the real service here is SID (the first is Xiao Li SID1, the second is Mei SID2, the third is one of the two)

2, Operation and maintenance Support Department, in the company internal communication platform to a virtual user (server_name), the user will submit feedback to the user, and then by the virtual user to dispatch the rear real node to provide services, using the Jira platform of the small partners should have deep feelings.

3, the user does not have the relationship, the real to provide me the service person is who, each time only needs to submit the question to this virtual user (server_name), will have the support personnel to solve my question.


Note: In this case, if the user knows who is in the operations department, can also be configured to directly assign the problem to such as Xiao Li, that is, in the configuration database connection information, can be configured as a direct connection SID, can also be configured as a connection server_name, and then by Server_ Name to regulate the SID to process the request.


Summarize:


Sid:

A database can have multiple instances (such as a RAC cluster environment), and the SID identifies each instance within the database as if it were a department where everyone had a name (Xiao Li and Mei, etc.).


SERVICE_NAME:

The database declares its name as a department name, which is registered with the listener of the database. The janitor look at you is looking for service_name this department (Operation and maintenance department), tell you that our company does have this department, so you find, the connection is established.


For a cluster, the SID for each node is different, but the service_name can contain all nodes.


In a word, it is:

The SID is internal, a name for the instance level that is used for inter-database salutation.

Service_ is external, is a database level name, used to tell the outside people, my database is called "service_name".

You can use the service_name parameter to specify what the name is, you can have more than one name, name casually, called Lao Wang, Lao Zhang is all right. If you do not specify, the default is db_name. Db_domain, Global_name.


These confusing names, as long as you remember, they are not referring to the database, that is, the example, there are two things, nothing else. The specific name they use depends on the object. Whether it is a request to the database, to the operating system, or to an external connection. It's not easy to confuse this.



End:



Thank you for reading, I wish you a rewarding day, thank you!





This article is from the "Breeze Month Blog" blog, please be sure to keep this source http://watchmen.blog.51cto.com/6091957/1928387

Understanding of server_name and SID Concepts in Oracle

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.