openldap-server增加group分组
2019-04-11openldap-server安装好之后,用ldapadd增加几个目录为了管理用户和分组分组,然后就可以用ldapadmin登陆管理openldap了。
1、ldapadd -x -D cn=Manager,dc=looyu,dc=com -W -f 1basedomain.ldif
2、cat 1basedomain.ldif
##################################
dn: dc=looyu,dc=com
o: com
dc: looyu
objectClass: top
objectClass: dcObject
objectclass: organization
dn: cn=Manager,dc=looyu,dc=com
cn: Manager
objectClass: organizationalRole
description: Directory Manager
dn: ou=People,dc=looyu,dc=com
ou: People
objectClass: top
objectClass: organizationalUnit
dn: ou=Group,dc=looyu,dc=com
ou: Group
objectClass: top
objectClass: organizationalUnit
##################################
或者
2basedomain.ldif
###################################
# replace to your own domain name for "dc=***,dc=***" section
dn: dc=looyu,dc=com
objectClass: top
objectClass: dcObject
objectclass: organization
o: com
dc: looyu
dn: cn=Manager,dc=looyu,dc=com
objectClass: organizationalRole
cn: Manager
description: Directory Manager
dn: ou=Users,dc=looyu,dc=com
objectClass: organizationalUnit
ou: Users
dn: ou=Group,dc=looyu,dc=com
objectClass: organizationalUnit
ou: Group
dn: ou=Sudoers,dc=looyu,dc=com
objectClass: organizationalUnit
ou: sudoers