Migration 迁移过程中的POSKeyError

Migration 迁移过程中的POSKeyError,migration,plone,Migration,Plone,从plone 3.3.2迁移到plone 4.2.1失败,出现PosKeyError。我试过这篇文章中的食谱。 我已经运行了error_finder代码段,但它没有给我任何异常。我还尝试使用app.mysite在调试器中获取对象。_p_jar[p64(oid)]-也没有成功,它失败了,出现了相同的错误 如何删除损坏的对象或至少获取有关对象的更多信息(例如,其类名或位置) 完全回溯: POSKeyError('\x00\x00\x00\x00\x00\x0ey=',) (Also, the fol

从plone 3.3.2迁移到plone 4.2.1失败,出现PosKeyError。我试过这篇文章中的食谱。 我已经运行了error_finder代码段,但它没有给我任何异常。我还尝试使用
app.mysite在调试器中获取对象。_p_jar[p64(oid)]
-也没有成功,它失败了,出现了相同的错误

如何删除损坏的对象或至少获取有关对象的更多信息(例如,其类名或位置)

完全回溯:

POSKeyError('\x00\x00\x00\x00\x00\x0ey=',)
(Also, the following error occurred while attempting to render the standard error message, please see the event log for full details:
An operation previously failed, with traceback: 
File "/Users/makmak/Plone/buildout-cache/eggs/Zope2-2.13.16-py2.7.egg/ZServer/PubCore/ZServerPublisher.py", line 31, in __init__
  response=b) 
File "/Users/makmak/Plone/buildout-cache/eggs/Zope2-2.13.16-py2.7.egg/ZPublisher/Publish.py", line 443, in publish_module
  environ, debug, request, response)
File "/Users/makmak/Plone/buildout-cache/eggs/Zope2-2.13.16-py2.7.egg/ZPublisher/Publish.py", line 237, in publish_module_standard
  response = publish(request, module_name, after_list, debug=debug)
File "/Users/makmak/Plone/buildout-cache/eggs/Zope2-2.13.16-py2.7.egg/ZPublisher/Publish.py", line 134, in publish
  transactions_manager.commit()
File "/Users/makmak/Plone/buildout-cache/eggs/Zope2-2.13.16-py2.7.egg/Zope2/App/startup.py", line 301, in commit
  transaction.commit()
File "/Users/makmak/Plone/buildout-cache/eggs/transaction-1.1.1-py2.7.egg/transaction/_manager.py", line 89, in commit
  return self.get().commit()
File "/Users/makmak/Plone/buildout-cache/eggs/transaction-1.1.1-py2.7.egg/transaction/_transaction.py", line 336, in commit
  t, v, tb = self._saveAndGetCommitishError()
File "/Users/makmak/Plone/buildout-cache/eggs/transaction-1.1.1-py2.7.egg/transaction/_transaction.py", line 329, in commit
  self._commitResources()
File "/Users/makmak/Plone/buildout-cache/eggs/transaction-1.1.1-py2.7.egg/transaction/_transaction.py", line 443, in _commitResources
  rm.commit(self)
File "/Users/makmak/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-macosx-10.4-x86_64.egg/ZODB/Connection.py", line 572, in commit
  oid, serial, transaction)
File "/Users/makmak/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-macosx-10.4-x86_64.egg/ZODB/BaseStorage.py", line 416, in checkCurrentSerialInTransaction
  committed_tid = self.getTid(oid)
File "/Users/makmak/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-macosx-10.4-x86_64.egg/ZODB/FileStorage/FileStorage.py", line 770, in getTid
  with self._lock:
File "/Users/makmak/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-macosx-10.4-x86_64.egg/ZODB/FileStorage/FileStorage.py", line 403, in _lookup_pos
  raise POSKeyError(oid)
POSKeyError: 0x0e793d

可以使用fsrefs.py查找坏对象


关于使用它的一篇非常简短的文章是:

您可以使用fsrefs.py查找坏对象


关于如何使用它的一篇非常简短的文章是:

我相信这是一种情况,如果回滚了一个保存点,包括向目录添加一个对象,就会发生这种情况。我认为这是ZODB中的一个bug,但是您可以通过解决回滚保存点的任何问题来解决它,在本例中,就是将文件和图像迁移到blob。因此,如果您解决了使这些文件或图像无法成功迁移到blob(或仅删除它们)的问题,则应该会成功。

我相信,如果回滚保存点(包括向目录添加对象),则会发生这种情况。我认为这是ZODB中的一个bug,但是您可以通过解决回滚保存点的任何问题来解决它,在本例中,就是将文件和图像迁移到blob。因此,如果您修复了使这些文件或图像无法成功迁移到blob(或仅删除它们)的原因,则应该会成功。

t在plone 3站点上清除并重建门户目录后,错误消失。我想,破碎的物体是一个目录大脑,在重建过程中被移除。不确定,但fsrefs脚本似乎没有扫描目录大脑,这就是为什么它没有给我任何输出。在plone 3站点上清除并重建门户目录后,错误消失了。我想,破碎的物体是一个目录大脑,在重建过程中被移除。不确定,但fsrefs脚本似乎没有扫描目录大脑,这就是为什么它没有给我任何输出。