Restore-SPSite Error: 0x80070003 on Backup-Restore SharePoint Site Collection Between Different Farms

When I was trying to backup restore between SharePoint DEV and QA Farms got this error message: Restore-SPSite : <nativehr>0x80070003</nativehr><nativestack></nativestack>
Restore-SPSite : <nativehr>0x80070003</nativehr><nativestack></nativestack>” src=”https://www.sharepointdiary.com/wp-content/uploads/2020/12/restore-spsite-error-nativehr-0x80070003-nativestack-on-backup-restore-between-different-farms.png” border=”0″></a></p>



<h2 class=Root Cause:

The source and target SharePoint Farm’s build version mismatch!

Solution:

Upgrade either the source or destination SharePoint farm and then backup-restore.

Backdoor way:
What if you don’t have the option of immediate upgrade and complete this backup restore operation? Here is the backdoor way to skip upgrades and backup-restore SharePoint sites or lists between farms with different versions/build numbers.

One way is: Backup-restore the content database of your old SharePoint site collection to the target farm. Mount and Upgrade the content database (Mount-SPContentDatabase followed by Upgrade-SPContentDatabase) in the target farm.

There is another way: Binary Edit! Just open the backup file in any HEX editor tool; I’ve used HxD from: https://mh-nexus.de/en/hxd/, and change the version build number to your target SharePoint farm version.
SharePoint Restore-SPSite Error:0x80070003
Try restoring the site collection again; It should work now.

Other Cases

1: Restore Operation interrupted and site corrupted:

I experienced the same issue when the restore operation got interrupted in another case. Since the restore is stopped in the middle, that left the site in an unsupported state. So, the solution is: Delete the partially restored site and run restore again. Here is how: How to Delete Corrupted Site Collections in SharePoint using PowerShell?

2. Database is not upgraded:

If the content database in which site collection exists – is not already upgraded to the current SharePoint build version, You’ll receive this error. Solution? Do: Upgrade-SPContentDatabase “DatabaseName” before taking backup (or make sure the target database is upgraded!)

3. Last but not least: The user who runs the backup-restore doesn’t have enough permission on SQL Server!

Salaudeen Rajack

Salaudeen Rajack - Information Technology Expert with Two-decades of hands-on experience, specializing in SharePoint, PowerShell, Microsoft 365, and related products. He has held various positions including SharePoint Architect, Administrator, Developer and consultant, has helped many organizations to implement and optimize SharePoint solutions. Known for his deep technical expertise, He's passionate about sharing the knowledge and insights to help others, through the real-world articles!

3 thoughts on “Restore-SPSite Error: 0x80070003 on Backup-Restore SharePoint Site Collection Between Different Farms

  • Hi Salaudeen, I tried with 2nd option editing with HEX- editor. No luck. I am facing below error
    Could not deserialize site from D:\SiteCollectionBackup\CPD.bak . System.Data.SqlClient.SqlException (0x80131904): The instance of the SQL Server Database Engine cannot obtain a LOCK resource at this time. Rerun your statement when there are fewer active users. Ask the database administrator to check the lock and memory configuration for this instance, or to check for long-running transactions. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
    Can you please help on this.

    Reply
  • Hi Salaudeen,
    Thanks for the solution.
    My case is Migration: Source: SPF Preview 2013 -> Destination: SPF 2013 SP1

    First, I tried the 2nd way with Hex-Editor. No luck 🙁
    But 1st way worked like a charm 🙂
    Mount-SPContentDatabase followed by Upgrade-SPContentDatabase

    –Muthukannan.G

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *