Home » RDBMS Server » Enterprise Manager » ORA-12154: TNS could not resolve service name
ORA-12154: TNS could not resolve service name [message #68289] Sun, 09 March 2003 22:02 Go to next message
sar
Messages: 2
Registered: March 2003
Junior Member
I have installed Oracle 8i EE on my AMD Duron based system woth Win98 SE as on OS. Installation was of both Client as well as programmer, but as soon as SQL *Plus is run after giving the login scott password tiger, it gives "ORA-12154: TNS could not resolve service name" error.

Any help for mw will be appreciated
Thanx
Re: ORA-12154: TNS could not resolve service name [message #68291 is a reply to message #68289] Mon, 10 March 2003 05:49 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10708
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
as per your posting
[i]
Installation was of both Client as well as programmer
[/i]
did you install the server or create a database?
then (if the client and database are in same machine) you can connect withput a string ie... usename/password.
else
you have to create a connectString..
edit your tnsnames.ora and add entries

Re: ORA-12154: TNS could not resolve service name [message #68293 is a reply to message #68289] Mon, 10 March 2003 12:16 Go to previous messageGo to next message
sar
Messages: 2
Registered: March 2003
Junior Member
I installed a server, and as per ur suggestion I tried to connect with the username and password but without Host String as both the client and server are on the same computer(stand alone).

This gave me an error:
ERROR:
ORA-12560: TNS: Protocol Adapter Error.

Pls suggest a way out now.
Thanx
Re: ORA-12154: TNS could not resolve service name [message #68675 is a reply to message #68289] Thu, 10 June 2004 21:46 Go to previous messageGo to next message
lily
Messages: 44
Registered: September 2000
Member
I encountered the problem in this way:

Through OEM, I could connect.
Through SQL+ on the same machine to the same database, got the error.

It is 9i on a xp machine.

Any suggestion on how to fix the SQL+?
Re: ORA-12154: TNS could not resolve service name [message #68835 is a reply to message #68675] Fri, 05 November 2004 14:29 Go to previous messageGo to next message
Cynthia
Messages: 18
Registered: February 2000
Junior Member
>I encountered the problem in this way:
>
>Through OEM, I could connect.
>Through SQL+ on the same machine to the same database, got the error.
>
>It is 9i on a xp machine.

>Any suggestion on how to fix the SQL+?

I have exactly the same problem... did you solve it Lily? if so, how?

Thanks in advance,
Cynthia
Re: ORA-12154: TNS could not resolve service name [message #68911 is a reply to message #68835] Wed, 02 February 2005 22:00 Go to previous messageGo to next message
rohit rajan
Messages: 3
Registered: May 2004
Junior Member
Hai

I could not solve this Problem. What does it actually mean. TNS could not resolve the service name.
My version is 8.i.7

bye
Re: ORA-12154: TNS could not resolve service name [message #113415 is a reply to message #68293] Sat, 02 April 2005 10:43 Go to previous messageGo to next message
Rans
Messages: 11
Registered: February 2005
Location: chennai
Junior Member
Even on the same machine I think you need to give host string else database(instance) identification would fail..
This may be the reason..
Can you explain your problem a litlle more in depth..


Rana
Re: ORA-12154: TNS could not resolve service name [message #113417 is a reply to message #68289] Sat, 02 April 2005 12:30 Go to previous message
William Robertson
Messages: 1643
Registered: August 2003
Location: London, UK
Senior Member
Notice the error you get when you supply an invalid service name:

/Users/williamr: sqlplus scott/tiger@nosuchdb

SQL*Plus: Release 9.2.0.1.0 - Developer's Release on Sat Apr 2 16:59:27 2005

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

ERROR:
ORA-12154: TNS:could not resolve service name

I get the same error if I rename tnsnames.ora (simulating what happens when your connection process cannot find it).

So, confirm that:
1. there is a tnsnames.ora file
2. it contains the service name you are using
3. the definition for that service is correct.

As for the rules for bypassing SQL*Net and connecting directly to a local database, I must admit they are not immediately obvious. I have a TNS listener running on my home system (not Windows) and I always use username/password@servicename. In theory if the TWO_TASK environment variable is set, it provides a default service name, though I can never get that to work so there is obviously more to it.
Previous Topic: OEM: I can't logon
Next Topic: Running oracle without tnslistener.ora and sqlnet.ora
Goto Forum:
  


Current Time: Tue Nov 26 14:05:54 CST 2024