Full_Name: Emmanuel L.charny Version: 2.4.40 OS: Linux URL: ftp://ftp.openldap.org/incoming/ Submission from: (NULL) (90.46.56.240) the back-meta overlay meta_back_init_one_conn() method set the timeout to get the result to a value which is not the one configured (network-timeout AFAIU), as shown in this portion of the code (line 469 in conn.c) : LDAP_BACK_TV_SET( &tv ); retry:; rc = ldap_result( msc->msc_ld, msgid, LDAP_MSG_ALL, &tv, &res ); which uses : #define LDAP_BACK_RESULT_TIMEOUT (0) #define LDAP_BACK_RESULT_UTIMEOUT (100000) #define LDAP_BACK_TV_SET(tv) \ do { \ (tv)->tv_sec = LDAP_BACK_RESULT_TIMEOUT; \ (tv)->tv_usec = LDAP_BACK_RESULT_UTIMEOUT; \ } while ( 0 ) The timeout is then set to 100ms, which might be too low when the remote server is 'far'.
moved from Incoming to Software Bugs
I don't think this is actually a bug. This is not what network_timeout is meant for. The timeout value for receiving a response is actually the per-operation timeouts, and these are, in fact, honored. ldap_result is called with a tv of LDAP_BACK_RESULT_UTIMEOUT to avoid multiple threads getting stuck waiting for the same connection to become available, but the call is repeated until the configured operation timeout is reached. This is how both back-ldap and back-meta operate, and it is by design. network-timeout is provided (by setting LDAP_OPT_NETWORK_TIMEOUT) to ldap_pvt_poll when a new connection is created or an ldap request is sent.