Bug#680363: cyrus-imapd-2.2: imapd gets mad falling into endless loop

Kiss Gabor (Bitman) kissg at ssg.ki.iif.hu
Tue Jul 10 12:19:15 UTC 2012


> > #0  0xb76f5424 in __kernel_vsyscall ()
> > #1  0xb71b096b in poll () from /lib/i686/cmov/libc.so.6
> > #2  0xb4ce4444 in ldap_int_select () from /usr/lib/libldap_r-2.4.so.2
> > #3  0xb4ccddbb in ldap_result () from /usr/lib/libldap_r-2.4.so.2
> > #4  0xb4b1191e in ?? () from /lib/libnss_ldap.so.2
> > #5  0xb4b11c38 in ?? () from /lib/libnss_ldap.so.2
> > #6  0xb4b14625 in _nss_ldap_endgrent () from /lib/libnss_ldap.so.2

Improved trace:

#0  0xb7754424 in __kernel_vsyscall ()
#1  0xb720f96b in poll () from /lib/i686/cmov/libc.so.6
#2  0xb4d43444 in ldap_int_select (ld=0x91a8638, timeout=0x0) at os-ip.c:1098
#3  0xb4d2cdbb in wait4msg (ld=0x91a8638, msgid=4, all=0, timeout=0x0, result=0x91afb64) at result.c:335
#4  ldap_result (ld=0x91a8638, msgid=4, all=0, timeout=0x0, result=0x91afb64) at result.c:120
#5  0xb4b7091e in ?? () from /lib/libnss_ldap.so.2
#6  0xb4b70c38 in ?? () from /lib/libnss_ldap.so.2
#7  0xb4b73625 in _nss_ldap_endgrent () from /lib/libnss_ldap.so.2
[...]

> 
> Yikes. It is caused by libnss-ldap.
> 
> > The bug may be in libldap-2.4-2 or libnss-ldap packages too...
> > Could you give me some hints? What should I check, recompile, sniff,
> > debug, peek, poke ... etc?
> 
> Usually the only correct way to deal with ldap-nss in the long term is to
> get rid of it :-(

Uhm... :-/

Actually I bet function wait4msg() in libraries/libldap/result.c
in OpenLDAP calls ldap_int_select() in endless loop with
zero timeout.

I tried to enable some debugging as I found on page
http://pic.dhe.ibm.com/infocenter/tivihelp/v2r1/topic/com.ibm.IBMDS.doc/pdguide32.htm
I added environment settings to /etc/init.d/cyrus-2.2:

export LDAP_DEBUG=LDAP_DEBUG_TRACE
export LDAP_DEBUG_FILE=/var/log/ldap.log
        if start-stop-daemon ${START} >/dev/null 2>&1 ; then
                echo "$NAME."
        else

I created a cyrus writable log file called /var/log/ldap.log
then I restarted Cyrus. However the file is remaining empty. :-(

Any idea will be appreciated.

Gabor
-- 
E-mail = m-mail * c-mail ^ 2





More information about the Pkg-Cyrus-imapd-Debian-devel mailing list