1 Reply Latest reply: Sep 18, 2013 2:33 AM by mbobak RSS

    SQL Developer 4.0 EA2 -- Cannot use OpenLDAP with LDAP connect option

    mbobak

      Hi,


      I've got OpenLDAP setup to work with my Oracle clients, to serve up TNS connect strings, in lieu of having tnsnames.ora files scattered about hundreds of servers.


      This is working fine with 10g/11g, both full and instant clients, no problem.


      Now, I'm trying to configure SQL Developer 4.0 EA2 working with it, as well.


      When I attempt to do so, I'm able to select the "LDAP" option in "Connection Type", and the "LDAP Server" drop down list is correctly populated with my LDAP server, from ldap.ora.


      However, when I select it, I get the following error:

      Status : Failure -[LDAP: error code 32 - No Such Object]


      Now, I've done some research, and I monitored the slapd.log file, which shows me the following:

      Sep 18 02:43:35 einstein slapd[2779]: conn=1034 fd=16 ACCEPT from IP=192.168.125.1:63781 (IP=0.0.0.0:389)

      Sep 18 02:43:35 einstein slapd[2779]: conn=1034 op=0 BIND dn="" method=128

      Sep 18 02:43:35 einstein slapd[2779]: conn=1034 op=0 RESULT tag=97 err=0 text=

      Sep 18 02:43:35 einstein slapd[2779]: conn=1034 op=1 SRCH base="" scope=2 deref=0 filter="(objectClass=orclContext)"

      Sep 18 02:43:35 einstein slapd[2779]: conn=1034 op=1 SEARCH RESULT tag=101 err=32 nentries=0 text=

      Sep 18 02:43:35 einstein slapd[2779]: conn=1034 op=2 UNBIND

      Sep 18 02:43:35 einstein slapd[2779]: conn=1034 fd=16 closed

       

      Which is a lot more detail, but reflects the corresponding error code, (32 - No Such Object).

       

      After doing some testing with ldapsearch, I've been able to replicate what SQL Developer is doing, and get the exact same error.

      That ldapsearch command is:

      ldapsearch -h einstein -p 389 -c -x -D "" -b "" "(objectClass=orclContext)"

       

      Looking in the slapd.log file, I find an identical error to what is produced from SQL Developer.

       

      Further, the query that SQL Developer wants to do can be successfully done with the following ldapsearch:

      ldapsearch -h einstein -p 389 -c -x -D "" -b "dc=proquest,dc=com" "(objectClass=orclContext)"

       

       

      So, it seems the problem is with the fact that SQL Developer is not supplying a search base.

       

      I'm no LDAP expert, and I'm really not sure where to turn next....

       

      Is there a SQL Developer option that allows me to set that search base?  Is there a configuration I'm missing on the LDAP server configuration?

       

      Thanks,

       

      -Mark

        • 1. Re: SQL Developer 4.0 EA2 -- Cannot use OpenLDAP with LDAP connect option
          mbobak

          Well, that didn't take long.  I managed to find a solution to the problem.

           

          It comes down to the fact that SQL Developer doesn't supply a search base, and my LDAP server didn't have a default search base defined.

           

          When I edited slapd.conf (the OpenLDAP config file) and added a "defaultsearchbase" parameter, and bounced the LDAP server, everything started to work.

           

          I now have a working configuration with OpenLDAP and SQL Developer.

           

          I'll mark this discussion as closed.

           

          -Mark