Tuesday, July 24, 2012

SharePoint Publishing Site Features: Error When Enabling Feature During Upgrade

I am sure most of you are either going through, or have completed, an upgrade from SharePoint 2007 to SharePoint 2010. I was recently tasked to migrate a SharePoint 2007 content database to an existing SharePoint 2010 farm. I received an error during the upgrade process which had very few related Google results. I am hoping my experience and knowledge gained through this process will help others receiving this same, and unusual error. 

To set the stage, the content database I was moving from SP2007 to SP2010 contained only one site collection and consisted of only a little over 10gb of data. Publishing site features were being used on this site, as well as workflows, lookup columns, and various other out-of-the-box features. No custom code was deployed to this site collection whatsoever. To begin, let me outlay the extremely simplified version of the migration process:
  1. Perform a backup of your content database in SP2007
  2. Restore the database in SP2010
  3. Attach the database to your SP2010 farm through PowerShell
During the database attach (which is the 'Mount-SPContentDatabase' PowerShell command) was where I received the error. I looked through the error logs and found this:

"Error: Feature upgrade incomplete for Feature 'Publishing Site' (ID:#######) in site 'http://#####'. Exception: Save Conflict. Your changes conflict with those made concurrently by another user. If you want your changes applied, click Back in your web browser, refresh the page, and resubmit your changes."

What is deceiving is that the site does migrate to SP2010 seemingly successfully and the error above occurs right at a 100% - right at the end of the database attach process. I felt uncomfortable with this and decided to do more digging. Unfortunately searching on the web for anything related to this specific error and exception is impossible. So here is my take on how to fix it...

Prior to performing a backup of your SP2007 content database, disable publishing features at both the site collection level and the site level. If you have sub-sites, disable the publishing feature there too. (You can do this through Site Actions -> Site Settings -> Site Collection Features and Manage Site Features.) After you have performed the backup, and restored to 2010, try performing the database attach through PowerShell. You should not receive any errors and this process should complete with no lovely red text at the end.

But wait, I need all of my Publishing Site Features back! You enable the SharePoint Server Publishing Site Infrastructure in the site collection but cannot enable the SharePoint Server Publishing feature for the rest of the sites! You receive this error:

"One or more field types are not installed properly. Go to List settings page to delete these fields."

What does this even mean?! What list are they referring to? And you thought you had it all figured out... Sorry, but there is one more thing you need to do and I swear it will be all done. 

Navigate to the root site in the site collection. You are looking for something called the Relationships list. Since you can't navigate to it, it's located at: http:///Relationships%20List/AllItems.aspx. 

Delete this List!

Go back and enable the SharePoint Server Publishing Site Infrastructure in the site collection and SharePoint Server Publishing feature for the rest of the sites. You should now be error free when it comes to the Publishing Site feature.

No comments:

Post a Comment