Oracle connection from .NET

Posted on 2005-04-30
Medium Priority
Last Modified: 2008-02-01
OK here's the deal. I am so frustrated right now because I keep having the same error and hope that someone out there smarter than me can come up with the fix. I've installed Oracle 10g on a W2k Server with SP4. I'm accessing it with .NET 2003 on a Windows XP SP2 machine which I have installed the Oracle 10g Data Provider for .NET(ODP.NET) . Everytime I try to connect to the the Oracle machine I get the following error. "TNS: listener does not currently know of service requested in connect descriptor". Everything I find on the mighty google tells me that it has to do with either my listener.ora, or tnsnames.ora file which I'm assuming is on the client not the server however none of them say anything about what it's supposed to look like. Also I can do a TNSPING just fine to the Oracle box.

I have the deepest appriciation and respect for anyone who is able to help me with a solution.
Question by:airwaysfreight
LVL 16

Expert Comment

by:Peter Kwan
ID: 13903689
1. Are you connecting to server using .NET program? If yes, can you please post your connection string?
2. Is there any firewall between the two machines? Please check the firewall settings.
3. Can you use sql plus in the client machine to connect to server machine?

Accepted Solution

helpneed earned 1500 total points
ID: 13907683

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.

Check to see if the service_name given in tnsnames.ora is correct.
If you have DB_DOMAIN=WORLD is set in init<sid>.ora or spfile, then the service name would be <sid>.WORLD. Check to see the service registration when you run lsnrctl status.

check for SQLNET.AUTHENTICATION_SERVICES= (NTS) in sqlnet .ora try to make it nione and proceed




Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

Truncate is a DDL Command where as Delete is a DML Command. Both will delete data from table, but what is the difference between these below statements truncate table <table_name> ?? delete from <table_name> ?? The first command cannot be …
Cursors in Oracle: A cursor is used to process individual rows returned by database system for a query. In oracle every SQL statement executed by the oracle server has a private area. This area contains information about the SQL statement and the…
Via a live example, show how to take different types of Oracle backups using RMAN.
This video shows how to Export data from an Oracle database using the Datapump Export Utility.  The corresponding Datapump Import utility is also discussed and demonstrated.
Suggested Courses
Course of the Month14 days, 6 hours left to enroll

807 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