ldap安装配置过程中遇到的错误,以及解决方法

错误1:

[root@openldap openldap]# ldapsearch -LLL-W -x -H ldap://etiantian.org -D "cn=admin,dc=etiantian,dc=org" -b"dc=etiantian,dc=org" "(uid=*)"

Enter LDAP Password:

ldap_bind: Invalid credentials (49)

错误描述:

搜选的时候,提示ldap_bind: Invalid credentials (49)

官方说是密码错误

其实是版本问题

 

ldap2.3和2.4配置冲突问题



 

解决方法:

rm -rf /etc/openldap/slapd.d/*

slaptest -f /etc/openldap/slapd.conf -F /etc/openldap/slapd.d/

ll /etc/openldap/slapd.d/

chown -R ldap.ldap /etc/openldap/slapd.d

/etc/init.d/slapd restart

OK搞定

 

错误2:

[root@openldap openldap]# slaptest -f /etc/openldap/slapd.conf -F /etc/openldap/slapd.d/

58116898 /etc/openldap/slapd.conf: line 139: <rootpw> can only be set when rootdn is under suffix

slaptest: bad configuration directory!

错误描述:

配置文件错误,是以下位置配置错误,注意符号

106 database        bdb

107 suffix    "dc=etiantian.dc=org"

108 checkpoint      1024 15

109 rootdn    "cn=admin,dc=etiantian,dc=org"

 

解决方法:

106 database        bdb

107 suffix    "dc=etiantian,dc=org"

108 checkpoint      1024 15

109 rootdn    "cn=admin,dc=etiantian,dc=org"

 

错误3:

[root@openldap openldap]# /etc/init.d/slapd restart

Stopping slapd:                                            [  OK  ]

Checking configuration files for slapd:                    [FAILED]

58116b90 ldif_read_file: Permission denied for"/etc/openldap/slapd.d/cn=config.ldif"

slaptest: bad configuration file!

 

错误描述:

    重启的时候Permission denied,说明权限不够

 

解决方法:

    chown -R ldap.ldap/etc/openldap/slapd.d

    /etc/init.d/slapd restart

posted @   ma_fighting  阅读(5958)  评论(3编辑  收藏  举报
编辑推荐:
· .NET Core 中如何实现缓存的预热?
· 从 HTTP 原因短语缺失研究 HTTP/2 和 HTTP/3 的设计差异
· AI与.NET技术实操系列:向量存储与相似性搜索在 .NET 中的实现
· 基于Microsoft.Extensions.AI核心库实现RAG应用
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
阅读排行:
· TypeScript + Deepseek 打造卜卦网站:技术与玄学的结合
· 阿里巴巴 QwQ-32B真的超越了 DeepSeek R-1吗?
· 【译】Visual Studio 中新的强大生产力特性
· 10年+ .NET Coder 心语 ── 封装的思维:从隐藏、稳定开始理解其本质意义
· 【设计模式】告别冗长if-else语句:使用策略模式优化代码结构
历史天气查
点击右上角即可分享
微信分享提示