[Zope] Re: Catalog problem
tseaver at zope.com
Wed Feb 9 07:47:20 EST 2005
-----BEGIN PGP SIGNED MESSAGE-----
Kevin Carlson wrote:
| I ran fsrefs, fstest and fsrecover all of which finished with no
That is good news, actually, as it suggests that the problem is
localized to the BTrees, which are usually reparable.
| However, when I try to repopulate the catalog, or traverse
| objects in a BTreeFolder2, I am getting a POSKeyError. I have 12,940
| objects stored in the BTreeFolder2 instance -- is there a practical
| limit to the number of objects one can store in one of these?
| If there is not a limit, does anyone have ideas on how I can "fix" the
| BTreeFolder2 since the fs* scripts don't seem to do the trick?
Try creating a new BTree for the folder, and then copying items, e.g.:
~ >>> new_tree = folder._tree.__class__()
~ >>> for k, v in folder._tree.items():
~ ... new_tree[k] = v
~ >>> folder._old_tree, folder._tree = folder._tree, tree
~ >>> get_transaction().commit()
For the indexes, it might be easier just to delete each borked index,
recreate it, and reindex it.
Tres Seaver tseaver at zope.com
Zope Corporation "Zope Dealers" http://www.zope.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the Zope