Thursday, January 7, 2010

Service Names Using LDAP Fails With TNS-03505 and ORA-12154

Problem Description
It is used LDAP, sqlnet.ora entry is NAMES.DIRECTORY_PATH = (LDAP) and Tnsping fails with TNS-03505: Failed to resolve name or TNS-12154 / ORA-12154: TNS:could not resolve service name.

Problem Symptom
- Service name is registered in Internet Directory tree.
- Internet Directory tree is configured for service name resolution.
- If we look at sqlnet.ora trace file we will see the text 'Directory server type is 4096'.

Cause of the Problem
In LDAP, the problem occurs if oracle cannot locate the ldap.ora file. Directory server type 4096 stands for "unknown", which indicates that the client is not able to pickup the ldap.ora file.

Solution of the Problem
If you use TNSNAMES.ORA then for the solution of this problem look at http://arjudba.blogspot.com/2010/01/troubleshoot-ora-12154-tns-12154-tns.html.

In case of LDAP configuration,
On windows, ensure that there is a correctly configured ldap.ora file on the client in the ORACLE_HOME\network\admin directory.

On Unix, ensure that ldap.ora file on the client exist on $ORACLE_HOME/network/admin
directory.
In some types of installations on unix, there may be an ldap.ora file in ORACLE_HOME\ldap\admin directory.

On Oracle9i the ldap.ora file can also be placed in the directory defined by the TNS_ADMIN environment variable.

Following is an example of ldap.ora:
DEFAULT_ADMIN_CONTEXT = "dc=no,dc=oracle,dc=com"
DIRECTORY_SERVERS= (hostname:389:636)
DIRECTORY_SERVER_TYPE = OID
Related Documents 
ORA-12560: TNS:protocol adapter error on windows machine while starting oracle 
ORA-12514: TNS:listener does not currently know of service requested in connect descriptor 
Startup fails with oracle error ORA-00119, ORA-00132
http://arjudba.blogspot.com/2010/01/troubleshoot-ora-12154-tns-12154-tns.html

No comments:

Post a Comment