# LDAP authentication error

**URL:** https://discuss.elastic.co/t/ldap-authentication-error/250118
**Category:** Elasticsearch
**Tags:** elastic-stack-security
**Created:** [September 28, 2020, 3:32am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118 "2020-09-28T03:32:26Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![lusynda](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lusynda/32/53557_2.png) [@lusynda](https://discuss.elastic.co/u/lusynda)
#### Post date: [September 28, 2020, 3:32am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118/1 "2020-09-28T03:32:26Z")

</div>

Hi all  
I have a little problems with authenticate to ldap server,  
i set it to work already but sometime the authen give me an error timeout,  
and all the time all of our account have to wait for some time to log in the server.  
Can anyone give me some ways to fix this problems.  
Thanks you for your time.

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [September 28, 2020, 4:02am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118/2 "2020-09-28T04:02:51Z")

</div>

What version are you on?  
What does your config look like?  
What are the errors you are seeing?  
What do the Elasticsearch logs show?

---

<div class="post-metadata">

### Author: ![lusynda](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lusynda/32/53557_2.png) [@lusynda](https://discuss.elastic.co/u/lusynda)
#### Post date: [September 28, 2020, 4:11am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118/3 "2020-09-28T04:11:20Z")

</div>

- The version iam using is 7.9.0
- The config is like this : (some info will be blank for security reason as i hope you can understand)

```auto
xpack:
  security:
    authc:
      realms:
        ldap:
          ldap1:
            order: 0
            url: ldap://:389
            bind_dn: ""
            user_search:
              base_dn: ""
              filter: "(&(objectClass=User)(cn={0}))"
            group_search:
              base_dn: ""
            files:
              role_mapping: "/etc/elasticsearch/role_mapping.yml"
            unmapped_groups_as_roles: false
        native:
          native1:
            order: 1

```

- The error from the log that i see are

```auto
com.unboundid.ldap.sdk.LDAPException: The asynchronous operation encountered a client-side timeout a
fter waiting 5000 milliseconds for a response to arrive.

com.unboundid.ldap.sdk.LDAPException: An error occurred while attempting to connect to server Domain
DnsZones.TE.TEST.VN:389: IOException(LDAPException(resultCode=91 (connect error), errorMessage='Unab
le to establish a connection to server DomainDnsZones.TE.TEST.VN/192.168.0.1:389 within the configure
d timeout of 5000 milliseconds.', ldapSDKVersion=4.0.8, revision=28812))

```

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [September 28, 2020, 4:12am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118/4 "2020-09-28T04:12:42Z")

</div>

Have you raised this question with your Elastic support contact?

---

<div class="post-metadata">

### Author: ![lusynda](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lusynda/32/53557_2.png) [@lusynda](https://discuss.elastic.co/u/lusynda)
#### Post date: [September 28, 2020, 4:17am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118/5 "2020-09-28T04:17:52Z")

</div>

I haven't since this is only an testing cluster to test new feature and it is trial license.

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [September 28, 2020, 4:20am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118/6 "2020-09-28T04:20:33Z")

</div>

Ok no worries, thought that was the case but wanted to make sure.

Do you have access to the LDAP server logs at the time of these timeouts to see if there is anything that correlates? Do you have a firewall or anything in between the systems that might be causing a disconnect?

---

<div class="post-metadata">

### Author: ![lusynda](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lusynda/32/53557_2.png) [@lusynda](https://discuss.elastic.co/u/lusynda)
#### Post date: [September 28, 2020, 8:36am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118/7 "2020-09-28T08:36:32Z")

</div>

Unfortunately i do not have the account on the ldap server so i cannot view the log there, are there any other ways for me to troubleshoot this problems.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [October 26, 2020, 8:36am UTC](https://discuss.elastic.co/t/ldap-authentication-error/250118/8 "2020-10-26T08:36:33Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
