Hello Anton/Mark, Thanks for quick reply.I need your help to resolve TCP/IP timeout issue for following scenario. We have valid LDAP connection and this connection is reused for ldap operation like search ,modify etc. Suppose LDAP server machine goes down but we have valid LDAP connection handle , we make some ldap operation using this LDAP connection handle but LDAP server is down now and the ldap operation API waits for TCP/IP timeout period(almost 15 minutes on Linux), which is not desirable. Is there some way we can make LDAP API to return after user defined timeout period, if LDAP server is down? We are using synchronous LDAP API and application used for it, is single threaded. Please let me know if there is any way, we can handle this scenario.
Thanks & Regards Binod kumar "Mark Smith" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Anton Bobrov wrote: >> LDAP_X_OPT_CONNECT_TIMEOUT is applicable only when a new connection >> being established. in your case that happens when you execute bind >> operation. now i dunno why your LDAP server is changing its IP addr >> dynamically and how it does the cleanup but normally you should get >> LDAP_SERVER_DOWN from ldap_search_s() if that happens clean. there >> were several fixes made to "connection down" handling in libldap >> since 5.08 version so you might wanna upgrade to the latest version >> and see if LDAP_SERVER_DOWN gets returned straight away or not. > > Also see this thread: > > http://groups.google.com/group/mozilla.dev.tech.ldap/browse_thread/thread/ab7604bb7265d0d0/77bcc1e41d1cde2f?lnk=st&q=PRLDAP_OPT_IO_MAX_TIMEOUT# > > Note that PRLDAP_OPT_IO_MAX_TIMEOUT is only useful if you can use > libprldap (generally used with SSL connections, but may be used always). > > -- > Mark Smith > Pearl Crescent > http://pearlcrescent.com/ _______________________________________________ dev-tech-ldap mailing list [email protected] https://lists.mozilla.org/listinfo/dev-tech-ldap
