首页 文章

随机OpenLdap超时问题

提问于
浏览
0

我目前正在EC2上的Ubuntu 12.04上运行OpenLdap 2.4.31 . 我遇到一个问题,当我对ldap服务器执行ldapsearch或ldapadd命令时,我会得到随机超时 .

对于ldap服务器实际上没有负载,我使用它们来为EC2内部主机名进行名称解析,并使用ldap作为puppet的外部节点分类器 .

超时发生时,我收到以下错误:

ldap_sasl_bind(SIMPLE):无法联系LDAP服务器

如果我重新运行命令它工作正常,这会导致我的自动化中的一些问题(虽然我可以对此进行错误检查,但它首先发生的事情似乎很奇怪) .

这是我的slapd.conf的副本(有一些env特定信息被注释掉)希望有人对我在配置中缺少的内容有一些建议以防止超时问题:

include /opt/openldap/openldap-2.4.31/etc/openldap/schema/core.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/collective.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/corba.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/cosine.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/duaconf.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/dyngroup.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/inetorgperson.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/java.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/misc.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/nis.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/openldap.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/ppolicy.schema
        include /opt/openldap/openldap-2.4.31/etc/openldap/schema/puppet.schema
        pidfile         /opt/openldap/openldap-2.4.31/var/run/slapd.pid
        argsfile        /opt/openldap/openldap-2.4.31/var/run/slapd.args
        loglevel 0
        serverID 001
        database bdb
        suffix    "dc=example,dc=local"
        rootdn    "cn=admin,dc=example,dc=local"
        rootpw    secret
        directory /opt/openldap/openldap-2.4.31/var/openldap-data
        idletimeout 120
        timelimit 300
        cachesize 2000
        syncrepl rid=000
          provider=ldap://10.10.10.10
          type=refreshAndPersist
          retry="5 5 10 +"
          searchbase="dc=example,dc=local"
          attrs="*,+"
          bindmethod=simple
          binddn="cn=admin,dc=example,dc=local"
          credentials=secret
        syncrepl rid=000
          provider=ldap://10.10.10.20
          type=refreshAndPersist
          retry="5 5 10 +"
          searchbase="dc=example,dc=local"
          attrs="*,+"
          bindmethod=simple
          binddn="cn=admin,dc=example,dc=local"
          credentials=secret
        index entryCSN eq
        index entryUUID eq
        mirrormode TRUE
        overlay syncprov
        syncprov-checkpoint 100 10

1 回答

  • 0

    忽略这个问题 . 我的自我修复自动化是错误的配置,并在事故中每分钟重新启动slapd进程 .

相关问题