Detect ldap connect_error and retry