“ldap_modify:其他(例如,特定于实现)错误(80)”使用ldapmodify时

当我尝试将模块添加到OpenLDAP(SLES12SP2)时,出现此错误

ldapmodify -Z -xWD cn=config -f /data/modify.ldif Enter LDAP Password: modifying entry "cn=module{0},cn=config" ldap_modify: Other (eg, implementation specific) error (80) additional info: <olcModuleLoad> handler exited with 1 

我得到同样的错误:

 ldapmodify -Y EXTERNAL -H ldapi:/// -f /data/modify.ldif 

这里是ldif:

 dn: cn=module{0},cn=config changetype: modify add: olcModuleLoad olcModuleLoad: {4}dyngroup 

对我来说,这看起来不错 – 问题是什么?

和ldapsearch,我得到这个:

 # ldapsearch -Y EXTERNAL -H ldapi:/// -b 'cn=module{0},cn=config' SASL/EXTERNAL authentication started SASL username: gidNumber=0+uidNumber=0,cn=peercred,cn=external,cn=auth SASL SSF: 0 # extended LDIF # # LDAPv3 # base <cn=module{0},cn=config> with scope subtree # filter: (objectclass=*) # requesting: ALL # # module{0}, config dn: cn=module{0},cn=config objectClass: olcModuleList cn: module{0} olcModulePath: /usr/lib/openldap olcModuleLoad: {0}back_bdb.so olcModuleLoad: {1}back_mdb.so olcModuleLoad: {2}back_hdb.so olcModuleLoad: {3}syncprov.so # search result search: 2 result: 0 Success # numResponses: 2 # numEntries: 1 

如果我将模块path添加到ldif:

 dn: cn=module{0},cn=config changetype: modify add: olcModuleLoad olcModuleLoad: {4}dyngroup olcModulePath: /usr/lib/openldap 

要么

 dn: cn=module{0},cn=config changetype: modify add: olcModuleLoad olcModuleLoad: {4}dyngroup olcModulePath: /usr/lib/openldap/modules 

我得到这个错误:

 # ldapmodify -Z -xWD cn=config -f /data/modify.ldif Enter LDAP Password: ldapmodify: wrong attributeType at line 5, entry "cn=module{0},cn=config" 

/ usr / lib / openldap目录:

 drwxr-xr-x 2 root root 4096 Jul 20 14:07 modules -rw-r--r-- 1 root root 76410 Oct 14 2016 pw-sha2.a -rw-r--r-- 1 root root 1008 Oct 14 2016 pw-sha2.la lrwxrwxrwx 1 root root 16 Jul 20 14:07 pw-sha2.so -> pw-sha2.so.0.0.0 lrwxrwxrwx 1 root root 16 Jul 20 14:07 pw-sha2.so.0 -> pw-sha2.so.0.0.0 -rwxr-xr-x 1 root root 22848 Oct 14 2016 pw-sha2.so.0.0.0 -rwxr-xr-x 1 root root 2094232 Oct 14 2016 slapd -rwxr-xr-x 1 root root 7049 Oct 14 2016 start 

和/ usr / lib / openldap / modules目录:

 lrwxrwxrwx 1 root root 23 Jul 20 14:07 accesslog-2.4.so.2 -> accesslog-2.4.so.2.10.4 -rwxr-xr-x 1 root root 49232 Oct 14 2016 accesslog-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1034 Oct 14 2016 accesslog.la lrwxrwxrwx 1 root root 23 Jul 20 14:07 accesslog.so -> accesslog-2.4.so.2.10.4 lrwxrwxrwx 1 root root 22 Jul 20 14:07 auditlog-2.4.so.2 -> auditlog-2.4.so.2.10.4 -rwxr-xr-x 1 root root 10736 Oct 14 2016 auditlog-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1028 Oct 14 2016 auditlog.la lrwxrwxrwx 1 root root 22 Jul 20 14:07 auditlog.so -> auditlog-2.4.so.2.10.4 lrwxrwxrwx 1 root root 21 Jul 20 14:07 collect-2.4.so.2 -> collect-2.4.so.2.10.4 -rwxr-xr-x 1 root root 10768 Oct 14 2016 collect-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1022 Oct 14 2016 collect.la lrwxrwxrwx 1 root root 21 Jul 20 14:07 collect.so -> collect-2.4.so.2.10.4 lrwxrwxrwx 1 root root 24 Jul 20 14:07 constraint-2.4.so.2 -> constraint-2.4.so.2.10.4 -rwxr-xr-x 1 root root 27408 Oct 14 2016 constraint-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1040 Oct 14 2016 constraint.la lrwxrwxrwx 1 root root 24 Jul 20 14:07 constraint.so -> constraint-2.4.so.2.10.4 lrwxrwxrwx 1 root root 17 Jul 20 14:07 dds-2.4.so.2 -> dds-2.4.so.2.10.4 -rwxr-xr-x 1 root root 36088 Oct 14 2016 dds-2.4.so.2.10.4 -rwxr-xr-x 1 root root 998 Oct 14 2016 dds.la lrwxrwxrwx 1 root root 17 Jul 20 14:07 dds.so -> dds-2.4.so.2.10.4 lrwxrwxrwx 1 root root 19 Jul 20 14:07 deref-2.4.so.2 -> deref-2.4.so.2.10.4 -rwxr-xr-x 1 root root 14600 Oct 14 2016 deref-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1010 Oct 14 2016 deref.la lrwxrwxrwx 1 root root 19 Jul 20 14:07 deref.so -> deref-2.4.so.2.10.4 lrwxrwxrwx 1 root root 22 Jul 20 14:07 dyngroup-2.4.so.2 -> dyngroup-2.4.so.2.10.4 -rwxr-xr-x 1 root root 10672 Oct 14 2016 dyngroup-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1028 Oct 14 2016 dyngroup.la lrwxrwxrwx 1 root root 22 Jul 20 14:07 dyngroup.so -> dyngroup-2.4.so.2.10.4 lrwxrwxrwx 1 root root 21 Jul 20 14:07 dynlist-2.4.so.2 -> dynlist-2.4.so.2.10.4 -rwxr-xr-x 1 root root 27536 Oct 14 2016 dynlist-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1022 Oct 14 2016 dynlist.la lrwxrwxrwx 1 root root 21 Jul 20 14:07 dynlist.so -> dynlist-2.4.so.2.10.4 lrwxrwxrwx 1 root root 22 Jul 20 14:07 memberof-2.4.so.2 -> memberof-2.4.so.2.10.4 -rwxr-xr-x 1 root root 35952 Oct 14 2016 memberof-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1028 Oct 14 2016 memberof.la lrwxrwxrwx 1 root root 22 Jul 20 14:07 memberof.so -> memberof-2.4.so.2.10.4 lrwxrwxrwx 1 root root 20 Jul 20 14:07 pcache-2.4.so.2 -> pcache-2.4.so.2.10.4 -rwxr-xr-x 1 root root 78240 Oct 14 2016 pcache-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1016 Oct 14 2016 pcache.la lrwxrwxrwx 1 root root 20 Jul 20 14:07 pcache.so -> pcache-2.4.so.2.10.4 lrwxrwxrwx 1 root root 20 Jul 20 14:07 refint-2.4.so.2 -> refint-2.4.so.2.10.4 -rwxr-xr-x 1 root root 23312 Oct 14 2016 refint-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1016 Oct 14 2016 refint.la lrwxrwxrwx 1 root root 20 Jul 20 14:07 refint.so -> refint-2.4.so.2.10.4 lrwxrwxrwx 1 root root 21 Jul 20 14:07 retcode-2.4.so.2 -> retcode-2.4.so.2.10.4 -rwxr-xr-x 1 root root 31776 Oct 14 2016 retcode-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1022 Oct 14 2016 retcode.la lrwxrwxrwx 1 root root 21 Jul 20 14:07 retcode.so -> retcode-2.4.so.2.10.4 lrwxrwxrwx 1 root root 17 Jul 20 14:07 rwm-2.4.so.2 -> rwm-2.4.so.2.10.4 -rwxr-xr-x 1 root root 61032 Oct 14 2016 rwm-2.4.so.2.10.4 -rwxr-xr-x 1 root root 998 Oct 14 2016 rwm.la lrwxrwxrwx 1 root root 17 Jul 20 14:07 rwm.so -> rwm-2.4.so.2.10.4 lrwxrwxrwx 1 root root 20 Jul 20 14:07 seqmod-2.4.so.2 -> seqmod-2.4.so.2.10.4 -rwxr-xr-x 1 root root 10400 Oct 14 2016 seqmod-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1016 Oct 14 2016 seqmod.la lrwxrwxrwx 1 root root 20 Jul 20 14:07 seqmod.so -> seqmod-2.4.so.2.10.4 lrwxrwxrwx 1 root root 20 Jul 20 14:07 sssvlv-2.4.so.2 -> sssvlv-2.4.so.2.10.4 -rwxr-xr-x 1 root root 27440 Oct 14 2016 sssvlv-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1016 Oct 14 2016 sssvlv.la lrwxrwxrwx 1 root root 20 Jul 20 14:07 sssvlv.so -> sssvlv-2.4.so.2.10.4 lrwxrwxrwx 1 root root 25 Jul 20 14:07 translucent-2.4.so.2 -> translucent-2.4.so.2.10.4 -rwxr-xr-x 1 root root 31920 Oct 14 2016 translucent-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1046 Oct 14 2016 translucent.la lrwxrwxrwx 1 root root 25 Jul 20 14:07 translucent.so -> translucent-2.4.so.2.10.4 lrwxrwxrwx 1 root root 20 Jul 20 14:07 unique-2.4.so.2 -> unique-2.4.so.2.10.4 -rwxr-xr-x 1 root root 27536 Oct 14 2016 unique-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1016 Oct 14 2016 unique.la lrwxrwxrwx 1 root root 20 Jul 20 14:07 unique.so -> unique-2.4.so.2.10.4 lrwxrwxrwx 1 root root 21 Jul 20 14:07 valsort-2.4.so.2 -> valsort-2.4.so.2.10.4 -rwxr-xr-x 1 root root 19184 Oct 14 2016 valsort-2.4.so.2.10.4 -rwxr-xr-x 1 root root 1022 Oct 14 2016 valsort.la lrwxrwxrwx 1 root root 21 Jul 20 14:07 valsort.so -> valsort-2.4.so.2.10.4