Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

tnsping is working ... but can not connect to db

Posted on 2010-12-28
13
Medium Priority
?
5,939 Views
Last Modified: 2013-12-18
Hi guys,

I'm able to ping my server and tnsping my db, but when trying to connect either using sqlplus or toad, giving this error:

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

Where as in toad, using TNSNames editor, able to test too and it can ping and also using network utilities it can ping & tnsping too ... but can't connect using sqlplus or even toad too.

Please assist, thanks.
0
Comment
Question by:el123
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
  • 3
  • +2
13 Comments
 
LVL 6

Expert Comment

by:anumoses
ID: 34438038
The ORA-12514 error is telling you that there is a mismatch between your TNS alias's SERVICE_NAME and the database server's SERVICE_NAME as defined for your Oracle Listener.
0
 
LVL 77

Expert Comment

by:slightwv (䄆 Netminder)
ID: 34438040
tnsping does not actually connect to database.  The listener on the machine does not know about the instance you are trying to connect to.

Check the listener.ora file on the database server to make sure it is listening for your instance: lsnrctl status
0
 

Author Comment

by:el123
ID: 34438059
no access to the db server
0
Nothing ever in the clear!

This technical paper will help you implement VMware’s VM encryption as well as implement Veeam encryption which together will achieve the nothing ever in the clear goal. If a bad guy steals VMs, backups or traffic they get nothing.

 
LVL 6

Expert Comment

by:anumoses
ID: 34438067
Are you running multiple oracle_homes on the server conflicting each others.
0
 
LVL 77

Expert Comment

by:slightwv (䄆 Netminder)
ID: 34438074
Then you have a problem.  That error is from the listener telling you something is not configured properly.

You will need to contact the DBA's on the server to provide you with the correct entries for your tnsnames.ora file.
0
 
LVL 6

Expert Comment

by:anumoses
ID: 34438099
Try Creating  a new environment variable called TNS_ADMIN:
in the ‘value’ field, add the new folder: c:\oracle\network\admin

Copy tnsnames.ora, sqlnet.ora and listener.ora from c:\oracle\product\102\network\admin
Paste into c:\oracle\network\admin

-- from command line
Stop/start listener
This can be done like this
C:\>lsnrctl stop
C:\>lsnrctl start
0
 

Author Comment

by:el123
ID: 34438125
but guys rememebr I'm able to tnsping ... so tnsping is working but sqlplus or toad, where as with in toad, its tools, network utilities or tnsnames editor are all working fine ... but can not connect and omarfarid ... user/pwd is secondary, first it'll try to connect then authtication will come into picture ... I think.
0
 
LVL 6

Expert Comment

by:anumoses
ID: 34438128
0
 
LVL 77

Accepted Solution

by:
slightwv (䄆 Netminder) earned 2000 total points
ID: 34438172
again: tnsping does not talk directly to the database.  Just that a listener is listening on the database server.

Check your tnsnames.ora file.  The service name you have must not match a service name being listened to on the database server.
0
 

Author Closing Comment

by:el123
ID: 34438367
Guru ... :-)
0
 
LVL 1

Expert Comment

by:tropically
ID: 35227784
Can you post the following
1) your tnsnames file
2) your sqlnet.ora file
3) The command you're using to connect to the database using sqlplus
4) Output of lsnrctl status.

Thanks
0
 
LVL 77

Expert Comment

by:slightwv (䄆 Netminder)
ID: 35228063
@tropically,

This question has been resolved and closed and has been for a long time.
0

Featured Post

Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
Shell script to create broker configuration file using current broker Configuration, solely for purpose of backup on Linux. Script may need to be modified depending on OS-installation. Please deploy and verify the script in a test environment.
Via a live example, show how to take different types of Oracle backups using RMAN.
This video shows how to recover a database from a user managed backup
Suggested Courses

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question