[Date Prev][Date Next] [Chronological] [Thread] [Top]

bug on dynamic configuration with back-sql



Hi,

I'm on Debian 6 / OpenLDAP 2.4.33 with back-sql.

According to http://www.openldap.org/software/release/changes.html, back-sql supports dynamic config as of version 2.4.27.

So I converted slapd.conf to slapd.d, conversion went well.

However, when I start slapd, I get the following message :
# /usr/local/libexec/slapd -u openldap -g openldap -d -1
.......
50ff3f0a <<< dnPrettyNormal: <cn=root,dc=example,dc=com>, <cn=root,dc=example,dc=com>
50ff3f0a olcSqlInsEntryStmt: value #0: <olcSqlInsEntryStmt> extra cruft after <SQL _expression_>.
50ff3f0a config error processing olcDatabase={1}sql,cn=config: <olcSqlInsEntryStmt> extra cruft after <SQL _expression_>
50ff3f0a send_ldap_result: conn=-1 op=0 p=0
50ff3f0a send_ldap_result: err=19 matched="" text=""
50ff3f0a slapd destroy: freeing system resources.
50ff3f0a slapd stopped.
50ff3f0a connections_destroy: nothing to destroy.


I took a look into olcDatabase={1}sql.ldif, and I saw that olcSqlInsEntryStmt was splitted on two lines :
olcSqlInsEntryStmt: insert into ldap_entries (id,dn,oc_map_id,parent,keyval) v
 alues ((select max(id)+1 from ldap_entries),?,?,?,?)

I tries to put everything on the same line, like :
olcSqlInsEntryStmt: insert into ldap_entries (id,dn,oc_map_id,parent,keyval) values ((select max(id)+1 from ldap_entries),?,?,?,?)


But the error persists.

If I comment that line, the server starts fine
# olcSqlInsEntryStmt: insert into ldap_entries (id,dn,oc_map_id,parent,keyval) values ((select max(id)+1 from ldap_entries),?,?,?,?)