LDAP - 无法添加OrganizationalUnit

时间:2014-04-11 17:51:36

标签: openldap

我是LDAP的新手并且加入了我的疯狂。

我使用以下代码为域创建数据库。每个域都有自己的数据库,因为它不再有效等等。

version: 1

dn: olcDatabase={1}hdb,cn=config
objectClass: olcDatabaseConfig
objectClass: olcHdbConfig
olcDatabase: {1}hdb
olcDbDirectory: /data/ldap/example.intra
olcAccess: {0}to attrs=userPassword,shadowLastChange by self write by anonymous auth by dn="cn=admin,dc=example,dc=intra" write by * none
olcAccess: {1}to dn.base="" by * read
olcAccess: {2}to * by self write by dn="cn=admin,dc=example,dc=intra" write by * read
olcDbCheckpoint: 512 30
olcDbConfig: {0}set_cachesize 0 2097152 0
olcDbConfig: {1}set_lk_max_objects 1500
olcDbConfig: {2}set_lk_max_locks 1500
olcDbConfig: {3}set_lk_max_lockers 1500
olcDbIndex: objectClass                 eq
olcDbIndex: sn                          pres,sub,eq
olcDbIndex: uid                         pres,sub,eq
olcDbIndex: displayName                 pres,sub,eq
olcDbIndex: cn                          pres,sub,eq
olcDbIndex: default                     sub
olcDbIndex: uidNumber                   eq
olcDbIndex: gidNumber                   eq
olcDbIndex: mail,givenName          eq,subinitial
olcDbIndex: dc                      eq
olcLastMod: TRUE
olcRootDN: cn=admin,dc=example,dc=intra
olcRootPW: {SSHA}fJnMxL3dHhxKhDkFyK/MwKeRB4iY/NQ0
olcSuffix: dc=example,dc=intra

当我尝试使用以下代码创建organizationalUnit时,它拒绝:

version: 1

dn: olcDatabase={1}hdb, cn=admin, ou=People, dc=example,dc=intra
changetype: modify
add: objectClass
objectClass: organizationalUnit
ou: People
description: All People and Human Like Entities in the example.intra Organisation

请一些非常好的人告诉我需要写什么来获取更新,如果可能的话,还有一些内容进入这个数据库?

我使用以下命令行来完成工作:

ldapadd -Y EXTERNAL -H ldapi:/// -f filename.ldif

这是我得到的回应:

SASL/EXTERNAL authentication started
SASL username: gidNumber=0+uidNumber=0,cn=peercred,cn=external,cn=auth
SASL SSF: 0
ldapadd: wrong attributeType at line 16, entry "olcDatabase={1}hdb, cn=admin, ou=People, dc=example,dc=intra"

谢谢和亲切的问候,

jB

0 个答案:

没有答案