[ZPatterns] Re: [Zope] ZCatalog: UnKeywordIndex error

Chris McDonough [email protected]
Wed, 12 Dec 2001 09:43:47 -0500


The two errors may be related but the FileStorage key error is
definitely the one you need to fix first.  This indicates that the
FileStorage index has become out-of-date or that the bits that make up
the data in the FileStorage are not in the place that the index thinks
they are.

Dont worry about the other error until you have this sorted out.  Try
a Data.fs backup or use the utilities/fsrecover.py script (or Ty's
tranalyzer) to attempt to detect where there is an index inconsistency
and fix the Data.fs.

This may be due to flaky hardware.  Hmm, you're not using your
FileStorage from an NFS mount are you?

----- Original Message -----
From: "Jean Jordaan" <[email protected]>
To: "Chris McDonough" <[email protected]>
Cc: <[email protected]>; <[email protected]>
Sent: Wednesday, December 12, 2001 9:18 AM
Subject: RE: [Zope] ZCatalog: UnKeywordIndex error


Hi Chris

> It can be fixed by rebuilding the catalog via "update catalog".

Hmm, sounds wonderful, but I've just done the following:

 - Create new blank ZCatalog

 - Run addIndexes script .. a lot of lines like::

   catalog.manage_addIndex('ComponentVersions', 'KeywordIndex')
   catalog.manage_addIndex('CreatedBy', 'TextIndex')

 - Run catalogEverything script .. a lot of loops like::

   ## ZClass instances
   ids = container.Reminders.getReminderIDs()
   for id in ids:
       object = container.Reminders[id]
       catalog.catalog_object(object,
string.join(object.getPhysicalPath(),
'/'))

   ## ZPatterns DataSkins
   ids =
container.Contacts.Resellers.defaultRack.getPersistentItemIDs()
   for id in ids:
       object = container.Contacts.Resellers.defaultRack.getItem(id)
       catalog.catalog_object(object,
string.join(object.getPhysicalPath(),
'/'))

And directly thereafter::

  2001-12-12T13:51:56 ERROR(200) UnKeywordIndex unindex_object could
  not remove documentId -215648165 from index ComponentVersions.
  This should not happen.
  Traceback (innermost last):
    File SearchIndex/UnIndex.py, line 236, in removeForwardIndexEntry
  KeyError: -215648165

This is when I attempt::

  license_propertysheet = license.propertysheets.basic
  license_propertysheet.manage_changeProperties(
      SystemReminders = system_reminders)

on the same 'license' instance (ZPatterns DataSkin ZClass) as before.
Entry -215648165 in the Catalog is the right one, indexed properly.

I see that I noticed the UnKeywordIndex errors before:
http://lists.zope.org/pipermail/zope/2001-November/104190.html
but then without a Zope Error being raised.

Currently, I'm seeing::

 Error Type: KeyError
 Error Value: AM¿ñÛS

 Traceback (innermost last):
  File ZPublisher/Publish.py, line 223, in publish_module
  File ZPublisher/Publish.py, line 187, in publish
  File Zope/__init__.py, line 221, in zpublisher_exception_hook
    (Object: ProviderContainer)
  File ZPublisher/Publish.py, line 175, in publish
  File Zope/__init__.py, line 235, in commit
  File ZODB/Transaction.py, line 300, in commit
  File ZODB/Connection.py, line 377, in commit
    (Info: (('BTrees.Length', 'Length'),
'\000\000\000\000\000\002D\367',
''))
  File ZODB/FileStorage.py, line 667, in store
    (Object: /home/httpd/zope-instances/dev-creme/var/Data.fs)
  File ZODB/ConflictResolution.py, line 174, in tryToResolveConflict
    (Object: /home/httpd/zope-instances/dev-creme/var/Data.fs)
  File ZODB/ConflictResolution.py, line 104, in state
    (Object: /home/httpd/zope-instances/dev-creme/var/Data.fs)
  File ZODB/FileStorage.py, line 612, in loadSerial
    (Object: /home/httpd/zope-instances/dev-creme/var/Data.fs)
 KeyError: (see above)

This one is actually the showstopper.

Jean


_______________________________________________
Zope maillist  -  [email protected]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )