[ZODB-Dev] ZODB packing error

Marius Gedminas mgedmin at b4net.lt
Wed Mar 31 06:55:31 EST 2004


On Tue, Mar 30, 2004 at 07:52:32PM -0500, Tim Peters wrote:
> >> I was testing a cron script to automatically pack the ZODB and
> >> noticed that after a few "packs" that some chunks of my Plone 2.0
> >> RC2 web site had vanished. Luckily I had a backup copy of Data.fs
> >> but this data loss event concerns me a lot. Has anyone else had a
> >> similar problem? I am using Zope 2.6.2.
> 
> [Marius Gedminas]
> > I've had a similar problem.  I believe I also used Zope 2.6.2 at the
> > time.

It was 2.6.1 actually.  http://mail.zope.org/pipermail/zope/2003-May/135603.html
I never found out the exact cause of that problem.

> > When you pack your database with 0 day history (which is very
> > helpfully the default setting in the ZMI), some objects are likely to
> > disappear. This happens they were they are only referenced from a
> > transaction that was not yet committed during the pack.  It is not
> > specific to 0-day packs, but it is more likely in this case.
> 
> If that's a new object, it will be added to the database when the
> transaction commits.  If it's an object that existed before the pack began,
> and was modified since, then it's quite possible that older revisions of the
> object vanish due to the pack.  Then when you try to commit the transaction,
> and if the revision current when the transaction began was removed by
> packing, you'll get a POSKeyError in the server log, and the client will see
> a ConflictError.  If it retries the transaction as a result, the new-new
> revision will get added to the database.

IOW there is no corruption.  I must have misunderstood the discussions
about 0-day packing I skimmed on zope and zodb-dev.

> We did fix one major bug of this kind "recently":  if you packed to a time
> earlier than a time previously packed to, it was possible to lose data.
> That's fixed in the current releases of ZODB.

Does this bug exist in 2.6.2 (the latest Zope packaged for Debian)?

Marius Gedminas
-- 
Key emulation:
[ ] Intuitive
[*] Emacs        (Seen in an MCEdit dialog) 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://mail.zope.org/pipermail/zodb-dev/attachments/20040331/86659f2b/attachment.bin


More information about the ZODB-Dev mailing list