[ZODB-Dev] Re: Can't pack ZODB anymore

Tim Peters tim at zope.com
Thu Aug 12 17:03:03 EDT 2004


[shan sverige, with at least one out-of-order tid]

[Dieter Maurer]
> Maybe, its "fsrecover" does?

I strongly recommend he try that only if the copyTransactionsFrom() method I
explained before doesn't work for him.  fsrecover "repairs" out-of-order
tids, but does so by throwing away transactions until it finds a larger tid
again.  That's extreme.  Since Shan's system clock disagreed with reality by
months, there's no guessing how much data that will throw away.  The
copyTransactionsFrom() gimmick doesn't throw any transactions away; instead
it "makes up" new tids for the out-of-order ones.

The only clear use for fsrecover I've heard of so far is to truncate a
FileStorage after a system crash -- but ZODB will usually do that by magic
when you next open the .fs file anyway.

Dieter, have you used fsrecover successfully for something fancier than just
that?  I've been asking around informally, and "truncate after crash" is all
I've heard.  In cases of bad-HW-induced .fs corruption, fsrecover never
seems to help in reality (for good reason:  it may need to throw away most
of the file, and doesn't have a chance of repairing corrupt bytes inside
object pickles anyway -- there's no substitute for good backups!).



More information about the ZODB-Dev mailing list