[Pkg-openldap-devel] Upgrades fail due to checkpoint directive
Steve Langasek
vorlon at debian.org
Fri Jan 11 01:20:28 UTC 2008
On Fri, Dec 21, 2007 at 03:31:37PM -0800, Russ Allbery wrote:
> The current slapd package writes a checkpoint configuration directive
> directly after the backend directive for bdb:
> backend bdb
> checkpoint 512 30
> OpenLDAP 2.4.7 can't cope with this:
> Loading from /var/backups/slapd-2.3.38-1:
> - directory dc=stanford,dc=edu... failed.
> Loading the database from the LDIF dump failed with the following
> error while running slapadd:
> /etc/ldap/slapd.conf: line 42: unknown directive <checkpoint> outside backend info and database definitions.
> slapadd: bad configuration file!
> Deleting the checkpoint configuration setting fixes the problem, as does
> moving it below the database and suffix settings.
> This is pretty bad. I'm not sure what to do about this. We could just
> remove checkpoint completely from the configuration, but my understanding
> is that it's important. Trying to figure out how to move it around in an
> arbitrary configuration file is going to be fairly hard.
> Why did upstream make this change? Was it actually intentional?
I don't understand why upstream would want to disallow setting global
defaults for the BDB backend, but anyway, here's a stab at migrating the
option from the backend config to the per-db config. It's based closely on
the existing write_slapd_conf function, but unfortunately that wants a
regexp which isn't practical here so that function can't be used directly.
Known flaw, if there's already a 'checkpoint' database directive in place
you'll now have two of them; but I think the last listed takes precedence
anyway so shouldn't have any practical effects.
Are we sure the 'checkpoint' option is the only one whose semantics have
changed? There are quite a few other options listed in slapd-bdb(5), I
don't know whether any of them were allowed in the 'backend' config before.
Well, easy enough to drop in handling for any other options we need to
shuffle around.
--
Steve Langasek Give me a lever long enough and a Free OS
Debian Developer to set it on, and I can move the world.
Ubuntu Developer http://www.debian.org/
slangasek at ubuntu.com vorlon at debian.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: move_checkpoint_option.diff
Type: text/x-diff
Size: 2470 bytes
Desc: not available
Url : http://lists.alioth.debian.org/pipermail/pkg-openldap-devel/attachments/20080110/033268b2/attachment.diff
More information about the Pkg-openldap-devel
mailing list