Pirate Pirate - 29 days ago 12
Vb.net Question

How to connect vb.Net application to Oracle using LDAP server?

For database connectivity to our Vb.net application we were using

Tnsnames.ora
.

But for now, We have the end files in a common LDAP server. We call it OID. We are stuck how to connect Oracle DB to our vb.net application using LDAP server.

Could you please provide any help regarding this.

Answer

When your names are provided from LDAP server then you don't need any tnsnames.ora file anymore.

In order to use LDAP server you have to change attribute NAMES.DIRECTORY_PATH in your sqlnet.ora file like this:

NAMES.DIRECTORY_PATH= (LDAP, TNSNAMES)

This will first search in LDAP and - if nothing found - then search tnsnames.ora file.

Then you have to create a file called ldap.ora in the same directory with content similar to this:

DEFAULT_ADMIN_CONTEXT = "dc=domain,dc=net"
DIRECTORY_SERVERS = (ldap-server1.domain.net:389:636,ldap-server2.domain.net:389:636)
DIRECTORY_SERVER_TYPE = OID

Check documentation for details:

Directory Usage Parameters (ldap.ora)

Parameters for the sqlnet.ora File