Home  >  Article  >  Database  >  What is a service name in oracle

What is a service name in oracle

WBOY
WBOYOriginal
2022-03-02 11:11:4412222browse

In Oracle, the service name refers to the external service name provided by the listener. The parameter name is "SERVICE_NAME". The service name can be registered statically in the "listener.ora" file or dynamically in the initialization file. Registration can be checked with "lsnrctl-sevice".

What is a service name in oracle

The operating environment of this tutorial: Windows 10 system, Oracle 11g version, Dell G3 computer.

What is a service name in oracle

Service name (service_names): refers to the external service name provided by the listener. The client can connect by configuring tnsnmaes.ora connection,

## The service_name in the #tnsnmaes.ora file must be equal to the service name registered by the server-side listener.

The service name can be viewed by entering lsnrctl and then entering service. The general service_name is configured in the listener.ora file (static Registration),

Or when there is no listener.ora file, configure the two parameters instance_name and service_names in the initialization file for dynamic registration.

But no matter which registration method is used, it can be checked through lsnrctl-sevice.

Starting from the oracle9i version, a new parameter is introduced, namely the database service name. The parameter name is SERVICE_NAME.

If the database has a domain name, the database service name is the global database name; otherwise, the database service name is the same as the database name.

Query database service name

Method one:

select value from v$parameter where name = 'service_name';

Method two:

show parameter service_name

Method three: Query in the parameter file.

Database service name and network connection

From the oracle network component opened by oracle8i, the host string for connecting the database to the client uses the database service name. Previously, ORACLE_SID was used, which is the database instance name

Recommended tutorial: "

Oracle Video Tutorial"

The above is the detailed content of What is a service name in oracle. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn