Доброго времени суток,
пытаюсь поставить OpenLDAP на Ubuntu 10.04 LTS установка прохоит нормально, но при конфигурировании возникают ошибки(делаю по след. инструкциям):
http://www.atomatix.net/wiki/index.php/Openldap_ubuntu_10.04_pdchttp://doc.ubuntu.com/ubuntu/serverguide/C/openldap-server.htmlпосле того, как я пытаюсь добавить
backend.example.com.ldif через команду:
ldapadd -Y EXTERNAL -H ldapi:/// -f backend.example.com.ldif
появляется ошибка:
adding new entry "olcDatabase=hdb,cn=config"
ldap_add: Other (e.g., implementation specific) error (80)
additional info: <olcRootPW> can only be set when rootdn is under suffix
вродеб здесь пигут об этом баге:
http://www.openldap.org/lists/openldap-bugs/200506/msg00156.html> olcRootPW: value #0: <olcRootPW> can only be set when rootdn is under
> suffix
> slapd stopped.
The problem occurs because DNs that contain spaces are parsed as different
tokens unless they are enclosed within quotes; if you edit
slapd.d/cn\=config/olcDatabase\=\{1\}bdb.ldif and put quotes around the
value of olcRootDN it will work. This is a bug that affects all
occurrences of DN-valued attributes in back-config.
There might be different solutions, which should be dicussed on -devel:
- EMIT DN-valued attributes wrapped in double quotes (") e.g. by defining
a value_add_one_quoted() helper that wraps the calls to value_add_one();
- parse DN-valued attributes differently from other values, e.g. by
glueing together tokens 1 to argc-1 (this sounds like a hack, and may
cause trouble with slapd.conf parsing);
- other...
if you edit slapd.d/cn\=config/olcDatabase\=\{1\}bdb.ldif and put quotes around the
value of olcRootDN it will workно в директории
/etc/ldap/slapd.d/cn=config я не нашел
olcDatabase\=\{1\}bdb.ldifroot@ldap:/etc/ldap/slapd.d/cn=config# ls
cn=module{0}.ldif cn=schema cn=schema.ldif olcDatabase={0}config.ldif olcDatabase={-1}frontend.ldif
что делать, помогите:
далее привожу конфиг
backend.example.com.ldif # Load dynamic backend modules
dn: cn=module,cn=config
objectClass: olcModuleList
cn: module
olcModulepath: /usr/lib/ldap
olcModuleload: back_hdb
# Database settings
dn: olcDatabase=hdb,cn=config
objectClass: olcDatabaseConfig
objectClass: olcHdbConfig
olcDatabase: {1}hdb
olcSuffix: dc=example,dc=com
olcDbDirectory: /var/lib/ldap
#changed this, test if it works now.
olcRootDN: cn=admin,dc=example,dc=com,cn=config
olcRootPW: {SSHA}zHqbvHs0Km5c+yCKyVg2/B2hYhiYPcfY
olcDbConfig: set_cachesize 0 2097152 0
olcDbConfig: set_lk_max_objects 1500
olcDbConfig: set_lk_max_locks 1500
olcDbConfig: set_lk_max_lockers 1500
olcDbIndex: objectClass eq
olcLastMod: TRUE
olcDbCheckpoint: 512 30
olcAccess: to attrs=userPassword by dn="cn=admin,dc=example,dc=com" write by anonymous auth by self write by * none
olcAccess: to attrs=shadowLastChange by self write by * read
olcAccess: to dn.base="" by * read
olcAccess: to * by dn="cn=admin,dc=example,dc=com" write by * read