操作系统:Debian 8
我使用buildout将Plone站点从4.3.6升级到4.3.8。 然后,当我尝试将其从4.3.8升级到5.0.2(复制并粘贴Data.fs和blobstorage)时,错误显示如下:
KeyError('Interface `Products.CMFPlone.interfaces.controlpanel.ILanguageSchema` defines a field `available_languages`, for which there is no record.',) (Also, the following error occurred while attempting to render the standard error message, please see the event log for full details: Interface `Products.CMFPlone.interfaces.controlpanel.ILanguageSchema` defines a field `available_languages`, for which there is no record.)
当我尝试查看该网站时,错误显示如下:
Starting the migration from version: 4312
Ran upgrade step: Miscellaneous
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Ran upgrade step: Run to50alpha3 upgrade profile
Ran upgrade step: Upgrade editing control panel settings
Ran upgrade step: Upgrade maintenance control panel settings
Ran upgrade step: Upgrade navigation control panel settings
Ran upgrade step: Upgrade search control panel settings
Ran upgrade step: Upgrade site control panel settings
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Skins tool imported.
Archetype tool imported.
Step languagetool has an invalid import handler
Ran upgrade step: Run to50beta1 upgrade profile
Ran upgrade step: Upgrade markup control panel settings
Ran upgrade step: Upgrade mail control panel settings
Ran upgrade step: Upgrade security control panel settings
Ran upgrade step: Remove Language Tool and migrate settings
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Ran upgrade step: Run to50beta2 upgrade profile
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Actions tool imported.
Control panel imported.
Archetype tool imported.
Step languagetool has an invalid import handler
Removed record plone.resources/mockup-patterns-accessibility.init.
Removed record plone.resources/mockup-patterns-accessibility.export.
Removed record plone.resources/mockup-patterns-accessibility.deps.
Removed record plone.resources/mockup-patterns-accessibility.conf.
Removed record plone.resources/mockup-patterns-accessibility.url.
Removed record plone.resources/mockup-patterns-accessibility.css.
Removed record plone.resources/mockup-patterns-accessibility.js.
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Ran upgrade step: Run to50beta3 upgrade profile
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Actions tool imported.
Archetype tool imported.
Step languagetool has an invalid import handler
Removed record plone.resources/mockup-patterns-tablesorter.init.
Removed record plone.resources/mockup-patterns-tablesorter.export.
Removed record plone.resources/mockup-patterns-tablesorter.deps.
Removed record plone.resources/mockup-patterns-tablesorter.conf.
Removed record plone.resources/mockup-patterns-tablesorter.url.
Removed record plone.resources/mockup-patterns-tablesorter.css.
Removed record plone.resources/mockup-patterns-tablesorter.js.
Removed record plone.resources/resource-collection-css.init.
Removed record plone.resources/resource-collection-css.export.
Removed record plone.resources/resource-collection-css.deps.
Removed record plone.resources/resource-collection-css.conf.
Removed record plone.resources/resource-collection-css.url.
Removed record plone.resources/resource-collection-css.css.
Removed record plone.resources/resource-collection-css.js.
Ran upgrade step: Run to50beta4 upgrade profile
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Ran upgrade step: Run to50beta4 upgrade profile
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Skins tool imported.
Archetype tool imported.
Step languagetool has an invalid import handler
Role / permission map imported.
Step collective.z3cform.datetimewidget has an invalid import handler
Archetype tool imported.
Step languagetool has an invalid import handler
Upgrade aborted. Error:
Traceback (most recent call last):
File "/opt/plone502/buildout-cache/eggs/Products.CMFPlone-5.0.2-py2.7.egg/Products/CMFPlone/MigrationTool.py", line 268, in upgrade
step['step'].doStep(setup)
File "/opt/plone502/buildout-cache/eggs/Products.GenericSetup-1.8.1-py2.7.egg/Products/GenericSetup/upgrade.py", line 166, in doStep
self.handler(tool)
File "/opt/plone502/buildout-cache/eggs/plone.app.upgrade-1.3.20-py2.7.egg/plone/app/upgrade/v50/betas.py", line 352, in to50rc1
qi.installProduct('plone.app.linkintegrity')
File "/opt/plone502/buildout-cache/eggs/Products.CMFQuickInstallerTool-3.0.13-py2.7.egg/Products/CMFQuickInstallerTool/QuickInstallerTool.py", line 603, in installProduct
blacklisted_steps=blacklistedSteps,
File "/opt/plone502/buildout-cache/eggs/Products.GenericSetup-1.8.1-py2.7.egg/Products/GenericSetup/tool.py", line 378, in runAllImportStepsFromProfile
dependency_strategy=dependency_strategy)
File "/opt/plone502/buildout-cache/eggs/Products.GenericSetup-1.8.1-py2.7.egg/Products/GenericSetup/tool.py", line 1310, in _runImportStepsFromContext
message = self._doRunImportStep(step, context)
File "/opt/plone502/buildout-cache/eggs/Products.GenericSetup-1.8.1-py2.7.egg/Products/GenericSetup/tool.py", line 1146, in _doRunImportStep
return handler(context)
File "/opt/plone502/buildout-cache/eggs/plone.app.intid-1.1.0-py2.7.egg/plone/app/intid/setuphandlers.py", line 66, in registerContent
registered, existing = register_all_content_for_intids(portal)
File "/opt/plone502/buildout-cache/eggs/plone.app.intid-1.1.0-py2.7.egg/plone/app/intid/setuphandlers.py", line 41, in register_all_content_for_intids
obj = brain.getObject()
File "/opt/plone502/buildout-cache/eggs/Products.ZCatalog-3.0.2-py2.7.egg/Products/ZCatalog/CatalogBrains.py", line 108, in getObject
return parent.restrictedTraverse(path[-1])
File "/opt/plone502/buildout-cache/eggs/Zope2-2.13.23-py2.7.egg/OFS/Traversable.py", line 317, in restrictedTraverse
return self.unrestrictedTraverse(path, default, restricted=True)
File "/opt/plone502/buildout-cache/eggs/Zope2-2.13.23-py2.7.egg/OFS/Traversable.py", line 300, in unrestrictedTraverse
raise e
NotFound: 1306115487
End of upgrade path, main migration has finished.
The upgrade path did NOT reach current version.
Migration has failed
今天(20160323),根据毛里求斯的建议,我直接升级网站。再次升级失败:
{{1}}
网站的主页显示相同的错误。
答案 0 :(得分:1)
我在问题"大脑"的10位数字标识符时遇到了同样的错误。我的80,000个对象的portal_catalog有三个导致此升级步骤失败。为了解决这个问题,我首先在plone 5站点上确定了有问题的对象,然后返回到plone 4站点并删除了对象。之后升级到plone 5成功完成。其中两个对象是讨论项目,第三个是有一个讨论项目的文档。
请注意,我现在意识到在plone 4.1之后我没有将讨论评论迁移到新系统(在plone 4讨论设置中我有一个警告:"您的评论尚未迁移到新评论已经在Plone 4.1中引入的系统。请迁移你的意见以解决这个问题。") - 也许这也解决了这个问题。
要查找有问题的对象,请在调试模式下启动plone 5实例:
sudo bin/instance debug
并输入以下内容:
from Products.CMFCore.utils import getToolByName
site = app['YourSiteName']
zcatalog = getToolByName(site, 'portal_catalog')
cnt=0
brains = zcatalog.unrestrictedSearchResults()
for brain in brains:
obj = brain._unrestrictedGetObject()
cnt +=1
如果存在有问题的对象,您将看到错误消息。用它来识别对象:
brains[cnt].getPath()
要检查多个有问题的对象,您可以修改上面的代码段。
答案 1 :(得分:0)
线索位于您粘贴的第一个文本的末尾:
Your Plone instance is now up-to-date.
Dry run selected, transaction aborted
所以它会起作用,但你选择了干跑,所以没有任何改变。当您尝试查看该站点时,事情会失败,因为代码期望升级已经运行。
所以:再试一次,但这次不要选择干运行选项。