Using DBCA, the Global database name is: prod.origtec.com Sid:prod
An Oracle database was uniquely identified by a Global database name,typically of the form "Name.domain"
Global Database Name:
A database is referenced by at least one Oracle instance which are uniquely identified form any other instance on this comp Uter by an Oracle System identifier (SID).
Configure Enterprise Manager not selected here, after the database is installed, use NETCA to create the listener.
Below use NETCA to create listen, each step i;
Figure 1
Figure 2
(for remote connections to being made to your Oracle database you must has at least one Oracle Net listener)
Figure 3
Figure 4
Figure 5
Figure 6
Figure 7
Figure 8
Figure 9
Each Oracle database or service has a service name. An Oracle database's service name is normally its global database name. Enter the service name of the database or other service, want to access.
Figure 10
Figure 11
Figure 12
Figure 13
Figure 14
Change Login, input password
Figure 15
Figure 16
Enter a name for the This net service name.
The Oracle net Configuration Assistant have default the net service name to being the same as the service name you entered ear Lier.
Figure 17
Figure 18
Figure 19
Figure 20
Host name is secondary.origtec.com
Using NETCA to create a listening and local network service, Listener.ora and Tnsnames.ora are generated separately under $oracle_home/network/admin
Start creating the database, there is no Listener.ora and Tnsnames.ora, of course, if you choose Configuration Enterprise Manager, you have to create a listener, create the listener will generate Listener.ora.
The version of Oracle is:
First of all, test the network configuration is normal
1). Monitor to start
2). Use SYS and the SYSTEM account
Sqlplus sys/[email protected] as Sysdba
Sqlplus system/[email protected]
Success!!!
Conn sys/[email protected] as Sysdba
Conn system/[email protected]
Failed!!!
Now, let's take a look at the specifics of Listener.ora and Tnsnames.ora.
Listener.ora
LISTENER This is the default name, the other seems to be nothing, protocol and host in address, Port is easy to understand
Finally there is a adr_base_listener =/u01/app/oracle
Explanation of official documents:
(http://docs.oracle.com/cd/E11882_01/network.112/e10835/listener.htm#NETRF420)
Adr_base_listener_name
Purpose
To specify the base directory in to which tracing and logging incidents was stored when ADR was enabled.
Defult
The default is Oracle_base, or oracle_home/log if oracle_base are not defined.
Values
Any valid directory path to a directory with write Permisson.
Example
Adr_base=/oracle/network/trace
About the enabled view of ADR:
SELECT Name,value from V$diag_info;
And look at Tnsnames.ora.
Line 10th (service_name = prod.origtec.com), where prod.origtec.com is the global Database NAME, as shown in Figure 10 above, SERVICE NAME
The prod in line 4th is the net Service Name in Figure 17
So conn sys/[email protected] as SYSDBA in the prod is the net Service Name, of course, the case is different, in case of capitalization test, should also be possible.
Correct syntax:
Connect username/[email protected]_service_name
I have been wrong to build Tnsnames.ora, Service name directly written prod, actually did not care when I built the library when the global database name is prod.origtec.com, and Sid is different, Sid is prod
Global database name= DB name + database domain name
Sid:
Query database service Name:
The service Name in Figure 10
Net_service_name In addition to Tnsnames.ora view, temporarily found no other way to view.
The following paragraph is from: http://www.2cto.com/database/201110/108457.html
Describes the global database name and SID, service name, and so on
“
DB Instance name and Oracle_sid
Although both tables are Oracle instances, there is a difference between the two. Instance_name is an Oracle database parameter. ORACLE_SID is an environment variable for the operating system. Oracld_sid is used to interact with the operating system, that is, to access the instance name from the operating system's perspective and must pass ORACLE_SID. In the Winnt, Oracle_sid also needs to exist in the registry.
And the Oracle_sid must match the value of the instance_name, otherwise you will receive an error on the UNIX platform, which is "ORACLE not available" on the Winnt platform, which is "TNS: Protocol Adapter Error".
“
The above used origtec.com domain name, the owner is the Suzhou traceability Tiancheng Information Technology Services Co., Ltd.
Oracle's Listener.ora, Tnsnames.ora configuration