yum  -y install   openldap  openldap-*

 yum  -y install nscd nss-pam-ldapd    pcre  pcre-*  

yum  -y install nss-*  

yum  -y install nss


[root@ldap-server openldap-servers]# cp  slapd.conf.obsolete  /etc/openldap/slapd.conf 

[root@ldap-server openldap-servers]# pwd

/usr/share/openldap-servers

[root@ldap-server openldap-servers]# 

[root@ldap-server openldap]# pwd

/etc/openldap

[root@ldap-server openldap]# slappasswd   -s  oldboy|sed  -e 's#{SSHA}#rootpw\t{SSHA}#g' >>slapd.conf 

[root@ldap-server openldap]# tail -1 slapd.conf

rootpw{SSHA}+OjqniWD7vyzN9D9vRbYRE6KvI3Hjrw1

[root@ldap-server openldap]# cp slapd.conf   slapd.conf.ori 

[root@ldap-server openldap]# pwd

/etc/openldap




[root@ldap-server openldap]# vim slapd.conf 

database        bdb

suffix          "dc=etiantian,dc=org"

#checkpoint     1024 15

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

ldap管理员的用户名密码:admin  oldboy


先修改默认的配置

wKioL1jV1abRtiPMAABSwg4F94k941.png-wh_50