Full_Name: Rein Tollevik Version: CVS head OS: linux and solaris URL: ftp://ftp.openldap.org/incoming/ Submission from: (NULL) (81.93.160.250) Submitted by: rein
Dynamically adding databases that requires renumbering of the existing olcDatabase values could also renumber the config database. But the code expects that to always be index 0, and slapd fails to start again. The "prod" server from test053-syncprov-glue shows a case where this would happen.
The patch at the end prevents config_renumber_one() from renumbering the config database. Howard, is this OK?
Rein Tollevik Basefarm AS
diff -u -r1.335 bconfig.c --- servers/slapd/bconfig.c 16 Jun 2008 12:45:30 -0000 1.335 +++ servers/slapd/bconfig.c 20 Jun 2008 14:39:41 -0000 @@ -3762,6 +3762,10 @@ char ibuf[32], *ptr1, *ptr2 = NULL; int rc = 0;
+ if ( !strncmp( e->e_nname.bv_val, "olcDatabase={0}config,", + STRLENOF("olcDatabase={0}config,") )) + return 0; + rc = config_rename_attr( rs, e, &rdn, &a ); if ( rc ) return rc;