-
Hi everybody !
I've encountered a very strange behavior with the tnsping command ...
I know that tnsping's response is OK when the service is declared in the listener.
But when I change the tnsnames.ora file, and put an unknown SID (XXXX for example), it's work fine too !
It seems that the tnsping only test the Listener even if the SID does not exists ...
Any idea ?
-
Listener use 2 types of service registration:
1. STATIC (from listener.ora file)
2. DYNAMIC (using IPC communication with oracle background processes)
when u set up sid name to XXX listener created two SERVICES:
- 1 from listener.ora (XXX)
- 2 from ur real oracle instance (ZZZ)
This is example :
LSNRCTL> status
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=xxx.aaa.com)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Solaris: Version 8.1.7.2.0 - Production
Start Date 19-AUG-2002 09:51:44
UptLime 0 days 3 hr. 36 min. 35 sec
Trace Level off
Security OFF
SNMP OFF
Listener Parameter File /opt/oracle/product/8.1.7/network/admin/listener.ora
Listener Log File /opt/oracle/product/8.1.7/network/log/listener.log
Services Summary...
PLSExtProc has 1 service handler(s)
oshare has 1 service handler(s)
then i changed listener.ora:
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = /opt/oracle/product/8.1.7)
(PROGRAM = extproc)
)
(SID_DESC =
(ORACLE_HOME = /opt/oracle/product/8.1.7)
(SID_NAME = xxxxxx)
)
)
Now SID NAME = xxxxx
LSNRCTL> reload
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=xxx.aaa.com)(PORT=1521)))
The command completed successfully
and try to check services, that work with listener:
SNRCTL> services
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=xxx.aaa.com)(PORT=1521)))
Services Summary...
PLSExtProc has 1 service handler(s)
DEDICATED SERVER established:0 refused:0
LOCAL SERVER
oshare has 1 service handler(s)
DEDICATED SERVER established:0 refused:0
LOCAL SERVER
xxxxxx has 1 service handler(s)
DEDICATED SERVER established:0 refused:0
LOCAL SERVER
The command completed successfully
OK! I can see 2 services:
1 from listener.ora, another form dynamic registration process.
TNSPING always check real oracle SID.
-
I'm sorry but I still don't understand ...
The listener.ora file contains several SID but not the XXX SID which does not exists.
Then I put SID=XXX into one address in the tnsnames.ora on the client side.
Then I've tried to execute tnsping on the client side to test the alias which reference the XXX SID.
And it works ...
Whatever I put on the (CONNECT_DATA=(SID=...)) string, tnsping always says OK !
Is that normal ?
-
Listener create SERVICE with name xxxx.
and When u try to check listener using:
tnsping xxx
where sid name = xxx, and real database for this sid doesn't exists,
then listener say to u --> OK! SERVICE (NOT SID) for sid xxx ESTABLISH !!!
(this isn't the same thing as EXISTS)
<--- THIS IS STATIC REGISTRATION OF SEVICES (NOT SIDs)
listener will try to create server process (or connect to dispatcher) ONLY
if u execute usual CONNECT command from a client mashine.
Another thing :
Doesn't matter u declared REAL INSTANCE in listener.ora file or not,
listener will use DYNAMIC REGISTRATION procedure for ESTABLISH this
instance in service list.
[Edited by Shestakov on 08-20-2002 at 12:12 PM]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|