1

This may sound stupid but i am running into situation where i have backup of content-db that had RBS enabled from SP 2010 and i am going to migrate it to SharePoint 2013.

I just have a backup , and i restored it in SQL 2014 but not attached to any web-application yet. How do i remove file stream blob and get those back in SQL from the content-db before attaching it to SharePoint?

1 Answer 1

2

You can move BLOBs back to the content database. If you do that, you still have the extended database-schema of RBS. If you also want to get rid of this, you should move your SiteCollections to a new content database. Then migrate it to SharePoint 2013.

  • Make sure you have enough diskspace on your SQL-Server to hold all migrated data

  • Check the number if externalized BLOBs in your database with the following SQL-Query:
    select COUNT(*) from AllDocStreams where RbsId is not null

  • Use the following PowerShell to migrate your data back to the database:

    $db= Get-SPContentDatabase -Name
    $rbs = $db.RemoteBlobStorageSettings
    $rbs.SetActiveProviderName("")
    $rbs.Migrate()

  • You should now get a number of 0 if you execute the SQL-Query from step 2 again. Please note that your BLOBs will not be deleted from your BLOB-Disk by the Migrate() function!

  • Create a new empty SharePoint contentdatabase via CentralAdmin or New-SPContentDatabase

  • Move your SiteCollections (one after each other) with Move-SPSite to your newly created contentdatabase (Move-SPSite http://servername/sites/sitename -DestinationDatabase YourNewDatabase)

  • Please note that your SiteCollection will not be available during the move-process. Moving large sites can take a lot of time (hours). Do not interrupt the process (CTRL+C) as it will result in a broken SiteCollection!

  • If no longer required, you can delete the old database with Remove-SPContentDatabase

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.