Home » RDBMS Server » Networking and Gateways » Connection error (Linux , Oracle 11g)
Connection error [message #403467] Fri, 15 May 2009 14:38 Go to next message
gkrishn
Messages: 506
Registered: December 2005
Location: Putty a dark screen
Senior Member
I get error when connect from 10g to 11g database.Both reside in same machine.

11g database
DB name:ora11gr1
version:11.1.0
TNSLSNR for Linux: Version 11.1.0.6.0

listener status
  Instance "ora11gr1", status READY, has 1 handler(s) for this service...


10g database
DB name:ora10gr1
version:10.2.0.3

TNSPING STATUS to 11g database :
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.165.9.70)(PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = ora11gr1)))
OK (0 msec)

But when i tried to connect to 11g database, it gives error

[oracle@myser1 admin]$ sqlplus strmadmin/strmadmin@ora11gr1.world

SQL*Plus: Release 10.2.0.3.0 - Production on Sat May 16 00:24:34 2009

Copyright (c) 1982, 2006, Oracle.  All Rights Reserved.

ERROR:
ORA-12514: TNS:listener does not currently know of service requested in connect
descriptor




Anyone has any idea what could be the issue here .Thanks
Re: Connection error [message #403468 is a reply to message #403467] Fri, 15 May 2009 14:41 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
what happens with the following
sqlplus strmadmin/strmadmin@ora11gr1
Re: Connection error [message #403469 is a reply to message #403467] Fri, 15 May 2009 14:42 Go to previous messageGo to next message
Michel Cadot
Messages: 68618
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
ORA-12514: TNS:listener does not currently know of service requested in connect descriptor
 *Cause:  The listener received a request to establish a connection to a
 database or other service. The connect descriptor received by the listener
 specified a service name for a service (usually a database service)
 that either has not yet dynamically registered with the listener or has
 not been statically configured for the listener.  This may be a temporary
 condition such as after the listener has started, but before the database
 instance has registered with the listener.
 *Action:
  - Wait a moment and try to connect a second time.
  - Check which services are currently known by the listener by executing:
    lsnrctl services <listener name>
  - Check that the SERVICE_NAME parameter in the connect descriptor of the
    net service name used specifies a service known by the listener.
  - If an easy connect naming connect identifier was used, check that
    the service name specified is a service known by the listener.
  - Check for an event in the listener.log file.

Regards
Michel
Re: Connection error [message #403471 is a reply to message #403467] Fri, 15 May 2009 14:45 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
Post the tnsnames.ora file.
Re: Connection error [message #403472 is a reply to message #403467] Fri, 15 May 2009 14:47 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
Which listener (V10 or V11) is running?

Does the running listener know about both database?

post the results from

lsnrctl services
Re: Connection error [message #403475 is a reply to message #403467] Fri, 15 May 2009 15:04 Go to previous messageGo to next message
gkrishn
Messages: 506
Registered: December 2005
Location: Putty a dark screen
Senior Member

11g side

LSNRCTL for Linux: Version 11.1.0.6.0

LSNRCTL> services
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=mysrv1)(PORT=1521)))
Services Summary...
Service "PRMRY" has 1 instance(s).
  Instance "ora11gr1", status READY, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:0 refused:0 state:ready
         LOCAL SERVER
Service "PRMRY_DGMGRL" has 1 instance(s).
  Instance "ora11gr1", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:0 refused:0
         LOCAL SERVER
Service "PRMRY_XPT" has 1 instance(s).
  Instance "ora11gr1", status READY, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:0 refused:0 state:ready
         LOCAL SERVER
Service "ora11gr1XDB" has 1 instance(s).
  Instance "ora11gr1", status READY, has 1 handler(s) for this service...
    Handler(s):
      "D000" established:0 refused:0 current:0 max:1022 state:ready
         DISPATCHER <machine: mysrv1, pid: 27460>
         (ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=47681))

The command completed successfully





TNS Entry, 10g side

ora11gr1.world=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.165.9.70)(PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = ora11gr1)))


[oracle@mysrv1 ~]$ sqlplus strmadmin/strmadmin@ora11gr1

SQL*Plus: Release 11.1.0.6.0 - Production on Sat May 16 00:56:57 2009

Copyright (c) 1982, 2007, Oracle.  All rights reserved.

ERROR:
ORA-12154: TNS:could not resolve the connect identifier specified

[Updated on: Fri, 15 May 2009 15:06]

Report message to a moderator

Re: Connection error [message #403480 is a reply to message #403467] Fri, 15 May 2009 15:30 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
post tail end of listener.log file
Re: Connection error [message #403482 is a reply to message #403467] Fri, 15 May 2009 15:43 Go to previous messageGo to next message
gkrishn
Messages: 506
Registered: December 2005
Location: Putty a dark screen
Senior Member
It is an XML file i have .

#this is When i tnsping 

<msg time='2009-05-16T01:41:02.879+05:30' org_id='oracle' comp_id='tnslsnr'
 type='UNKNOWN' level='16' host_id='mysrv1'
 host_addr='127.0.0.1'>
 <txt>16-MAY-2009 01:41:02 * ping * 0
 </txt>
</msg>



#during  sqlplus strmadmin/strmadmin@ora11gr1.world

<msg time='2009-05-16T01:41:54.389+05:30' org_id='oracle' comp_id='tnslsnr'
 type='UNKNOWN' level='16' host_id='mysrv1'
 host_addr='127.0.0.1'>
 <txt>16-MAY-2009 01:41:54 * (CONNECT_DATA=(SERVICE_NAME=ora11gr1)(CID=(PROGRAM=sqlplus)(HOST=mysrv1)(USER=oracle))) * (ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=17494)) * establish * ora11gr1 * 12514
 </txt>
</msg>
<msg time='2009-05-16T01:41:54.389+05:30' org_id='oracle' comp_id='tnslsnr'
 type='UNKNOWN' level='16' host_id='myserv1'
 host_addr='127.0.0.1'>
 <txt>TNS-12514: TNS:listener does not currently know of service requested in connect descriptor
 </txt>
</msg>

[Updated on: Fri, 15 May 2009 15:45]

Report message to a moderator

Re: Connection error [message #403490 is a reply to message #403467] Fri, 15 May 2009 17:09 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
SQL*net error is NOT difficult to understand.

message #403482 shows a request was made for SERVICE_NAME=ora11gr1

but throws an error reporting this SERVICE was not found.

message #403475 reports the listener knows the following SERVICES
Service "PRMRY" has 1 instance(s).
Service "PRMRY_DGMGRL" has 1 instance(s).
Service "PRMRY_XPT" has 1 instance(s).
Service "ora11gr1XDB" has 1 instance(s).

GUESS WHAT?
The V11 does not know about SERVICE_NAME=ora11gr1
So if you want to succeed, either use a known SERVICE or modify listener.ora to include "ora11grl".
Re: Connection error [message #403513 is a reply to message #403467] Sat, 16 May 2009 02:36 Go to previous message
gkrishn
Messages: 506
Registered: December 2005
Location: Putty a dark screen
Senior Member
i added "ora11gr1" service to 11g listener and reload it.

now i see

Service "ora11gr1" has 1 instance(s).
  Instance "ora11gr1", status UNKNOWN, has 1 handler(s) for this service...


and i could connect. Thaks Swan for your views. I was confused with the term Server&instance in listener stat .Thanks a lot .
Previous Topic: Link between Oracle and SQL server
Next Topic: extproc on another server
Goto Forum:
  


Current Time: Tue Mar 19 05:46:31 CDT 2024