repozo: a truncated .deltafs results in a corrupted Data.fs on recovery, instead of an error

Bug #906057 reported by Marius Gedminas
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ZODB
New
Undecided
Unassigned

Bug Description

You can truncate a *.deltafs in the middle, and repozo -R doesn't notice
-- it goes on to produce a corrupt Data.fs.

AFAIU the *.dat file contains enough information to do basic sanity
checking for the sizes of the various *.deltafs files. It'd be nice if
repozo -R noticed and aborted with a loud complaint when one of the
files is truncated. Checksum checking would be even nicer, but,
perhaps, expensive, and so maybe ought to require an extra command line
option to enable.

To reproduce:

  git clone git://github.com/mgedmin/repozo-testcases.git
  cd repozo-testcases
  make test2

Revision history for this message
Marius Gedminas (mgedmin) wrote :

I'm implementing a `repozo --verify` option to check *.fs/*.deltafs integrity against the *.dat file.

Revision history for this message
Marius Gedminas (mgedmin) wrote :

The feature is now implemented: https://github.com/zopefoundation/ZODB/pull/14

Revision history for this message
Marius Gedminas (mgedmin) wrote :

I would prefer repozo -R to do the checksum verification during recovery (unless you ask for --quick recovery).

But then I looked at the code and it seemed simpler to implement a standalone --verify, at least as a first step.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.