Plone migration from Plone 3.3.5 to Plone 4.3.9

I get this error

2017-04-01T15:41:53 INFO plone.app.upgrade Ran upgrade step: Add Site Administrator role
------
2017-04-01T15:41:53 ERROR ZODB.Connection Couldn't load state for 0x059d62
Traceback (most recent call last):
  File "/usr/local/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/ZODB/Connection.py", line 860, in setstate
    self._setstate(obj)
  File "/usr/local/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/ZODB/Connection.py", line 922, in _setstate
    obj._p_blob_committed = self._storage.loadBlob(obj._p_oid, serial)
  File "/usr/local/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/ZODB/Connection.py", line 1318, in loadBlob
    return self._storage.loadBlob(oid, serial)
  File "/usr/local/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/ZEO/ClientStorage.py", line 1020, in loadBlob
    raise POSException.POSKeyError("No blob file", oid, serial)
POSKeyError: 'No blob file'
------
2017-04-01T15:41:53 ERROR plone.app.upgrade Upgrade aborted. Error:
Traceback (most recent call last):
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFPlone-4.3.9-py2.7.egg/Products/CMFPlone/MigrationTool.py", line 259, in upgrade
    step['step'].doStep(setup)
  File "/usr/local/Plone/buildout-cache/eggs/Products.GenericSetup-1.8.2-py2.7.egg/Products/GenericSetup/upgrade.py", line 166, in doStep
    self.handler(tool)
  File "/usr/local/Plone/buildout-cache/eggs/plone.app.upgrade-1.3.22-py2.7.egg/plone/app/upgrade/v41/alphas.py", line 118, in update_role_mappings
    wtool.updateRoleMappings()
  File "<string>", line 4, in updateRoleMappings
  File "/usr/local/Plone/buildout-cache/eggs/AccessControl-3.0.11-py2.7-linux-x86_64.egg/AccessControl/requestmethod.py", line 70, in _curried
    return callable(*args, **kw)
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFCore-2.2.9-py2.7.egg/Products/CMFCore/WorkflowTool.py", line 454, in updateRoleMappings
    count = self._recursiveUpdateRoleMappings(portal, wfs)
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFCore-2.2.9-py2.7.egg/Products/CMFCore/WorkflowTool.py", line 606, in _recursiveUpdateRoleMappings
    count = count + self._recursiveUpdateRoleMappings(v, wfs)
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFCore-2.2.9-py2.7.egg/Products/CMFCore/WorkflowTool.py", line 606, in _recursiveUpdateRoleMappings
    count = count + self._recursiveUpdateRoleMappings(v, wfs)
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFCore-2.2.9-py2.7.egg/Products/CMFCore/WorkflowTool.py", line 606, in _recursiveUpdateRoleMappings
    count = count + self._recursiveUpdateRoleMappings(v, wfs)
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFCore-2.2.9-py2.7.egg/Products/CMFCore/WorkflowTool.py", line 606, in _recursiveUpdateRoleMappings
    count = count + self._recursiveUpdateRoleMappings(v, wfs)
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFCore-2.2.9-py2.7.egg/Products/CMFCore/WorkflowTool.py", line 597, in _recursiveUpdateRoleMappings
    ob.reindexObject(idxs=['allowedRolesAndUsers'])
  File "/usr/local/Plone/buildout-cache/eggs/Products.Archetypes-1.9.10-py2.7.egg/Products/Archetypes/CatalogMultiplex.py", line 120, in reindexObject
    c.catalog_object(self, url, idxs=lst)
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFPlone-4.3.9-py2.7.egg/Products/CMFPlone/CatalogTool.py", line 353, in catalog_object
    update_metadata, pghandler=pghandler)
  File "/usr/local/Plone/buildout-cache/eggs/Products.ZCatalog-2.13.27-py2.7.egg/Products/ZCatalog/ZCatalog.py", line 476, in catalog_object
    update_metadata=update_metadata)
  File "/usr/local/Plone/buildout-cache/eggs/Products.ZCatalog-2.13.27-py2.7.egg/Products/ZCatalog/Catalog.py", line 340, in catalogObject
    self.updateMetadata(object, uid, index)
  File "/usr/local/Plone/buildout-cache/eggs/Products.ZCatalog-2.13.27-py2.7.egg/Products/ZCatalog/Catalog.py", line 284, in updateMetadata
    newDataRecord = self.recordify(object)
  File "/usr/local/Plone/buildout-cache/eggs/Products.ZCatalog-2.13.27-py2.7.egg/Products/ZCatalog/Catalog.py", line 408, in recordify
    attr = getattr(object, x, MV)
  File "/usr/local/Plone/buildout-cache/eggs/plone.indexer-1.0.4-py2.7.egg/plone/indexer/wrapper.py", line 63, in __getattr__
    return indexer()
  File "/usr/local/Plone/buildout-cache/eggs/plone.indexer-1.0.4-py2.7.egg/plone/indexer/delegate.py", line 20, in __call__
    return self.callable(self.context)
  File "/usr/local/Plone/buildout-cache/eggs/Products.CMFPlone-4.3.9-py2.7.egg/Products/CMFPlone/CatalogTool.py", line 210, in getObjSize
    size = obj.get_size()
  File "/usr/local/Plone/buildout-cache/eggs/Products.ATContentTypes-2.1.18-py2.7.egg/Products/ATContentTypes/content/base.py", line 199, in get_size
    return f.get_size(self) or 0
  File "/usr/local/Plone/buildout-cache/eggs/plone.app.blob-1.5.17-py2.7.egg/plone/app/blob/field.py", line 321, in get_size
    return blob.get_size()
  File "/usr/local/Plone/buildout-cache/eggs/plone.app.blob-1.5.17-py2.7.egg/plone/app/blob/field.py", line 129, in get_size
    blob = openBlob(self.blob)
  File "/usr/local/Plone/buildout-cache/eggs/plone.app.blob-1.5.17-py2.7.egg/plone/app/blob/utils.py", line 52, in openBlob
    return blob.open(mode)
  File "/usr/local/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/ZODB/Connection.py", line 860, in setstate
    self._setstate(obj)
  File "/usr/local/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/ZODB/Connection.py", line 922, in _setstate
    obj._p_blob_committed = self._storage.loadBlob(obj._p_oid, serial)
  File "/usr/local/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/ZODB/Connection.py", line 1318, in loadBlob
    return self._storage.loadBlob(oid, serial)
  File "/usr/local/Plone/buildout-cache/eggs/ZODB3-3.10.5-py2.7-linux-x86_64.egg/ZEO/ClientStorage.py", line 1020, in loadBlob
    raise POSException.POSKeyError("No blob file", oid, serial)
POSKeyError: 'No blob file'
------
2017-04-01T15:41:54 INFO plone.app.upgrade End of upgrade path, main migration has finished.
------
2017-04-01T15:41:54 ERROR plone.app.upgrade The upgrade path did NOT reach current version.
------
2017-04-01T15:41:54 ERROR plone.app.upgrade Migration has failed
------
2017-04-01T15:41:54 INFO plone.app.upgrade Dry run selected, transaction aborted

How can I get through this error...

Need help

Looks like you may be missing blob files. Have you copied them over?

Yes

You can insert code right where the exception is thrown to get the full path of the missing file.

What do I do with the path

The path should be logged by default.

-aj

You use the path to go find the missing blob on the original site/server and copy it into the same place in the new site.

Size for blob which I was using was quite large so I also tried cleaning blob and bringing its size to 10 mb.
Is this a right approach to begin migration

What does that mean?

Renamed blobstorage to blobstorage123 and created a new directory with the name blobstorage and changed its ownership and group. Then tested the directory by adding new pdf and then removed blobstorage123.

I don't see what doing that has to do with the problem you had

I also tried cleaning blob and bringing its size to 10 mb.
I also tried cleaning blob
Then tested the directory by adding new pdf

I don't get why and how you did something like this. The blobs are added by Plone interface, not some file you add to folder by filesystem.

Check ./parts/instance/etc/zope.conf in your instance to make sure the defined folder for your blobstorage exists.

This file is usually dynamic generated by your buildout (check Installers-UnifiedInstaller/base_skeleton/base.cfg at 22e149c547304b790cb90ed1b50cdaf8a7ff02fb · plone/Installers-UnifiedInstaller · GitHub for an example), so check your buildout to avoid overriding stuff.

I am getting a new error now while upgrading

------
2017-04-12T19:29:39 INFO importVarious START
------
2017-04-12T19:29:39 ERROR GenericSetup Step kss_mimetype has an invalid import handler
------
2017-04-12T19:29:39 INFO plone.app.upgrade Ran upgrade step: General upgrade steps
------
2017-04-12T19:29:40 INFO plone.app.upgrade Ran upgrade step: Update the safe_html transform with the new config params, migrating existing config from Kupu.
------
2017-04-12T19:29:40 INFO plone.app.upgrade Updating `getIcon` metadata.
------
2017-04-12T19:29:40 ERROR plone.app.upgrade Upgrade aborted. Error:
Traceback (most recent call last):
  File "/usr/local/Plone4/buildout-cache/eggs/Products.CMFPlone-4.3.9-py2.7.egg/Products/CMFPlone/MigrationTool.py", line 259, in upgrade
    step['step'].doStep(setup)
  File "/usr/local/Plone4/buildout-cache/eggs/Products.GenericSetup-1.8.2-py2.7.egg/Products/GenericSetup/upgrade.py", line 166, in doStep
    self.handler(tool)
  File "/usr/local/Plone4/buildout-cache/eggs/plone.app.upgrade-1.3.22-py2.7.egg/plone/app/upgrade/v40/betas.py", line 85, in updateIconMetadata
    updateIconsInBrains(context, typesToUpdate)
  File "/usr/local/Plone4/buildout-cache/eggs/plone.app.upgrade-1.3.22-py2.7.egg/plone/app/upgrade/utils.py", line 227, in updateIconsInBrains
    brains = search(portal_type=empty_icons, sort_on="path")
  File "/usr/local/Plone4/buildout-cache/eggs/Products.CMFCore-2.2.9-py2.7.egg/Products/CMFCore/CatalogTool.py", line 245, in unrestrictedSearchResults
    return ZCatalog.searchResults(self, REQUEST, **kw)
  File "/usr/local/Plone4/buildout-cache/eggs/Products.ZCatalog-2.13.27-py2.7.egg/Products/ZCatalog/ZCatalog.py", line 604, in searchResults
    return self._catalog.searchResults(REQUEST, used, **kw)
  File "/usr/local/Plone4/buildout-cache/eggs/Products.ZCatalog-2.13.27-py2.7.egg/Products/ZCatalog/Catalog.py", line 916, in searchResults
    sort_index = self._getSortIndex(args)
  File "/usr/local/Plone4/buildout-cache/eggs/Products.ZCatalog-2.13.27-py2.7.egg/Products/ZCatalog/Catalog.py", line 889, in _getSortIndex
    sort_index_name)
CatalogError: Unknown sort_on index (path)
------
2017-04-12T19:30:02 INFO plone.app.upgrade End of upgrade path, main migration has finished.
------
2017-04-12T19:30:07 ERROR plone.app.upgrade The upgrade path did NOT reach current version.
------
2017-04-12T19:30:07 ERROR plone.app.upgrade Migration has failed

Any suggestions