Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Role of ORACLE_SID?
Volker Hetzer wrote:
> Hi!
> I've been debugging a log on problem for the last few days and I think I'm
> in the process of finding the error in my idea of how the oracle connection
> is established.
> So, can anybody explain to me the role of the environment variable ORACLE_SID
> in a scenario where the client sits on a different machine from the db server?
>
> I had assumed, when I set ORACLE_SID to the Db SID then sqlplus would,
> when called "sqlplus name/passwd" check the environment for the SID,
> consult tnsnames on where to find a db with that sid and then connect to it.
Close, but no tnsnames (or LDAP, or HOSTS, or whatever is defined in sqlnet.ora):
D:\oracle\817\bin>set ORACLE_SID=web920
D:\oracle\817\bin>sqlplus system/manager
SQL*Plus: Release 8.1.7.0.0 - Production on Thu May 22 20:52:33 2003
(c) Copyright 2000 Oracle Corporation. All rights reserved.
ERROR:
ORA-12560: TNS:protocol adapter error
Enter user-name:
D:\oracle\817\bin>type sqlnet.log
(DESCRIPTION=(ADDRESS=(PROTOCOL=BEQ)(PROGRAM=oracle)(ARGV0=oracleweb920)(ARGS=' (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))'))(CONNECT_DATA=(SID=web920)(C ID=(PROGRAM=D:\oracle\817\bin\SQLPLUS.EXE)(HOST=CS-FRANK02)(USER=frankbo))))
VERSION INFORMATION:
TNS for 32-bit Windows: Version 8.1.7.4.0 - Production Oracle Bequeath NT Protocol Adapter for 32-bit Windows: Version8.1.7.4.0 - Production
What happens is that the bequeth protocol kicks in - the only protocol
that does *not* need a listener, because it communicates directly to
the program stack.
So, it does not network, and cannot be used for remote connections.
The other side is, that the @networkDbName stuff is actually an alias.
It's perfectly ok to use: scott/tiger_at_bowie, where bowie is an alias
for an instance with a sid of jimmy:
BOWIE.CS.NL =
(DESCRIPTION =
(ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.200)(PORT = 1521)) ) (CONNECT_DATA = (SID = JIMMY) )
Hth,
-- Regards, Frank van BortelReceived on Thu May 22 2003 - 14:00:36 CDT
![]() |
![]() |