SharePoint: Mount-SPContentDatabase returns an “update conflict error”

I am currently on the process of upgrading our SharePoint 2007 infrastructure to SharePoint 2010 using the database attach procedure. However for the past two days I have been stuck with the following error when I tried to mount the SharePoint 2007 database in SharePoint 2010:

An update conflict has occurred, and you must re-try this action.

I was breaking my head crawling Google, Bing and Microsoft forums in trying to find a solution for this problem, until today when Microsoft forums saved the day. Read on for the solution.

Background

When upgrading to SharePoint 2010 there are two methods you can use:

  • In-place upgrade: Consists of installing SharePoint 2010 over SharePoint 2007. SharePoint 2010 set-up process will take care of the upgrade for you.
  • Database attach upgrade: Consists of installing SharePoint 2010 at another server to be side-by-side with the current SharePoint 2007. Then we gradually move the content we want from SharePoint 2007 to SharePoint 2010 using the “database attach method”.

For more information, check Microsoft’s TechNet library.

In my organisation the current SharePoint 2007 has been neglected for a long time, so when I joined I decided that we needed a fresh install. Therefore I decided in favour of a database attach approach.

The procedure

There are two great sources I used to perform the database upgrade approach. The first is Microsoft TechNet, the other is Bamboo Solutions community site. Here are the links:

  1. Microsoft TechNet: Prepare the new SharePoint Foundation 2010 environment for a database attach upgrade
  2. Microsoft TechNet: Attach databases and upgrade to SharePoint Foundation 2010
  3. Bamboo Nation: SharePoint 2010 Cookbook: How to Migrate a SharePoint 2007 Site to SharePoint 2010 Using Database Attach

In a nutshell, the process involves a backup of the content database I want to import into SharePoint 2010 to be restored in the SQL server used by SharePoint 2010. Then we create a new site in SharePoint 2010, detach its current content database and attach the SharePoint 2007 database. When attaching (mounting) the SharePoint 2007 database in SharePoint 2010, the procedure will also upgrade the content in the process.

The error

So I followed the documentation by the book. I made a backup of the content I want to import from SharePoint 2007 and I restored it on a separate database. However, when I logged into my SharePoint 2010 server and tried to attach the SharePoint 2007 database using the Mount-SPContentDatabase PowerShell command, I got the following error:

Mount-SPContentDatabase : An update conflict has occurred, and you must re-try this action. The object SPUpgradeSession Name=Upgrade-20110523-185120-830 was updated by DOMAIN\username, in the powershell (1532) process, on machine SP2010SERVER.  View the tracing log for more information about the conflict.
At line:1 char:24
+ Mount-SPContentDatabase <<<<  WSS_Content_DBNAME -WebApplication http://sp2010server:6789 -UpdateUserExperience
+ CategoryInfo          : InvalidData: (Microsoft.Share...ContentDatabase: SPCmdletMountContentDatabase) [Mount-SPContentDatabase], SPUpdatedConcurrencyException
+ FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletMountContentDatabase

Searching on the net for this error gave me little results. There is a Microsoft KB article (KB939308) which talks about a similar error which involves wiping out SharePoint’s cache. However it lead me nowhere. I tried posting on Microsoft’s community forum but it seems that nobody knew what was going on. I was ready to give up until I decided to repost my issue at Microsoft’s forum for partners. To my surprise, today I got an answer which solved my issue.

The solution

The solution involves synchronising the time between the SharePoint and the SQL server. Yes, really. That’s it. What surprises me the most was the time difference between the two: 10 minutes! I set the appropriate time for the SQL server and ran the Mount-SPContentDatabase PowerShell command once again on SharePoint 2010. This time I got no errors.

Thanks to Adam Zhu at Microsoft’s Partner forums for providing the solution!

4 Comments

  • Thanks. Just ran into this issue on a client site where just about every server has different time

  • Wow. I can't believe that with all the things going on during an upgrade, this is also an issue. You just saved my butt.

    Thanks!

  • Had the same problem. Should note the time zones have to be the same as well.

    • Thanks for the heads up!

Leave a comment