[ZODB-Dev] Relstorage pack problems

Santi Camps scamps at earcon.com
Mon Jan 19 04:51:13 EST 2009


Hi all

We've been using RelStorage 1.1.c1 in production environments over
postgresql 8.1 for some time.   It has been working really fine, but
yesterday we have a big problem packing a relstorage zodb mounted as a
zope mount point.

We use the attached script to do packs.   The log says all was fine:
"""
size:2580349576
packing...
size: 3422069432
Sun Jan 18 22:11:31 CET 2009
"""

But just one second later (22:11:32) a KeyError appears in event.log,
and the content of the database couldn't been seen in ZMI.   We try to
remount it, restart zope, and so on, but nothing works, so we had to
restore a backup.

That's the traceback of event.log:
Traceback (most recent call last):
File "/usr/local/zope/lib/python/ZODB/Connection.py", line 768, in setstate
self._setstate(obj)
File "/usr/local/zope/lib/python/ZODB/Connection.py", line 804, in _setstate
p, serial = self._storage.load(obj._p_oid, self._version)
File "/usr/lib/python2.4/site-packages/relstorage/relstorage.py", line
311, in load
self._log_keyerror(oid_int, "no tid found(2)")
File "/usr/lib/python2.4/site-packages/relstorage/relstorage.py", line
255, in _log_keyerror
rows = adapter.iter_object_history(cursor, oid_int)
File "/usr/lib/python2.4/site-packages/relstorage/adapters/common.py",
line 229, in iter_object_history
raise KeyError(oid)
KeyError: 7L

Anybody knows what could happen ?   Could be a problem access a
database during a pack process ?

Thanks in advance
--
Santi Camps (Earcon S.L.)
http://www.earcon.com
http://www.kmkey.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rspack.py
Type: text/x-python
Size: 1142 bytes
Desc: not available
Url : http://mail.zope.org/pipermail/zodb-dev/attachments/20090119/e6ab4cbe/attachment.py 


More information about the ZODB-Dev mailing list