From: Leons P. <le...@ca...> - 2007-12-19 19:06:04
|
Michael Str=F6der <mi...@st...> wrote on 18/12/2007 05:05:16 P= M: > Leons Petrazickis wrote: > > > > I've installed Thorsten Kurbad's python_ldap-2.3.1-py2.4-linux-i686= .egg on > > my Python 2.4 install > > Which OS? Which Linux distribution? Which OpenLDAP libs? I was using: Ubuntu 7.10 with Linux kernel 2.6.22-14-386 OpenLDAP 2.3.35-1ubuntu0.1 libsasl2 2.1.22.dfsg1-9ubuntu2 Python 2.4.4-6ubuntu4 Just now, I installed: OpenLDAP 2.3.39 This command worked fine: ldapsearch -h bluepages.ibm.com -P 2 -x -b "ou=3Dbluepages,o=3Dibm.com"= -s sub "(sn=3DLeon)" cn tieline But the python-ldap error stayed the same. I then compiled a custom copy of python-ldap 2.3.1. I got these warning= s during compilation: file Lib/ldap.py (for module ldap) not found file Lib/ldap/schema.py (for module ldap.schema) not found (The files are not in the download.) It compiled and installed without fatal errors. However, it now crashes= very differently: Traceback (most recent call last): File "test.py", line 10, in ? ldap.set_option(ldap.OPT_DEBUG_LEVEL,4095) File "/usr/lib/python2.4/site-packages/python_ldap-2.3.1-py2.4-linux-i686.eg= g/ldap/functions.py", line 126, in set_option _ldap_function_call(_ldap.set_option,option,invalue) AttributeError: 'module' object has no attribute 'set_option' Should I go back to the prebuilt .egg? > Hmm, yes something's really strange. > > If on Linux could you please check with ldd > <path-to-site-packages>/_ldap.so which OpenLDAP libs are actually use= d. With Ubuntu's OpenLDAP: linux-gate.so.1 =3D> (0xffffe000) libldap_r-2.3.so.0 =3D> /usr/lib/libldap_r-2.3.so.0 (0xb7f2a000) liblber-2.3.so.0 =3D> /usr/lib/liblber-2.3.so.0 (0xb7f1d000) libsasl2.so.2 =3D> /usr/lib/libsasl2.so.2 (0xb7f05000) libssl.so.0.9.8 =3D> /usr/lib/i686/cmov/libssl.so.0.9.8 (0xb7ec4000) libcrypto.so.0.9.8 =3D> /usr/lib/i686/cmov/libcrypto.so.0.9.8 (0xb7d810= 00) libpthread.so.0 =3D> /lib/tls/i686/cmov/libpthread.so.0 (0xb7d69000) libc.so.6 =3D> /lib/tls/i686/cmov/libc.so.6 (0xb7c1f000) libresolv.so.2 =3D> /lib/tls/i686/cmov/libresolv.so.2 (0xb7c0b000) libdl.so.2 =3D> /lib/tls/i686/cmov/libdl.so.2 (0xb7c07000) libz.so.1 =3D> /usr/lib/libz.so.1 (0xb7bf2000) /lib/ld-linux.so.2 (0x80000000) With custom OpenLDAP: linux-gate.so.1 =3D> (0xffffe000) libldap_r-2.3.so.0 =3D> /usr/lib/libldap_r-2.3.so.0 (0xb7ebd000) liblber-2.3.so.0 =3D> /usr/lib/liblber-2.3.so.0 (0xb7eb0000) libsasl2.so.2 =3D> /usr/lib/libsasl2.so.2 (0xb7e98000) libssl.so.0.9.8 =3D> /usr/lib/i686/cmov/libssl.so.0.9.8 (0xb7e57000) libcrypto.so.0.9.8 =3D> /usr/lib/i686/cmov/libcrypto.so.0.9.8 (0xb7d140= 00) libpthread.so.0 =3D> /lib/tls/i686/cmov/libpthread.so.0 (0xb7cfc000) libc.so.6 =3D> /lib/tls/i686/cmov/libc.so.6 (0xb7bb2000) libresolv.so.2 =3D> /lib/tls/i686/cmov/libresolv.so.2 (0xb7b9e000) libdl.so.2 =3D> /lib/tls/i686/cmov/libdl.so.2 (0xb7b9a000) libz.so.1 =3D> /usr/lib/libz.so.1 (0xb7b85000) /lib/ld-linux.so.2 (0x80000000) Regards, Leons Petrazickis http://lpetr.org/blog= |