Python LDAP

Juan okelet at gmail.com
Tue Aug 26 11:39:50 CEST 2008


Hi

I am trying to make a simple Python script using LDAP. The module is
imported OK, but when I call the function open or initialize, I get
this error:

Traceback (most recent call last):
  File "/home/juan/workspace/amquare/src/nutum/amquare/amquare.py",
line 122, in <module>
    conn.connect()
  File "/home/juan/workspace/amquare/src/nutum/amquare/ldap_util.py",
line 39, in connect
    self.conn = ldap.initialize(self.host, self.port)
  File "/usr/lib/python2.5/site-packages/ldap/functions.py", line 87,
in initialize
    return LDAPObject(uri,trace_level,trace_file,trace_stack_limit)
  File "/usr/lib/python2.5/site-packages/ldap/ldapobject.py", line 70,
in __init__
    self._l = ldap.functions._ldap_function_call(_ldap.initialize,uri)
  File "/usr/lib/python2.5/site-packages/ldap/functions.py", line 59,
in _ldap_function_call
    result = func(*args,**kwargs)
LDAPError: (2, 'No such file or directory')

What file is not found? I have lots of searches but don't get any
answer. Anyone know how to solve this?

Thanks in advance.



More information about the Python-list mailing list