Question

I am using SP2013 on-premise standard edition. In a site collection we have built a local term set group with 100+ termsets. We are going to use Backup-SPSite & Restore-SPSite to copy this site collection to another SP2013 farm. As far as I understand, the local term set group is not saved in the content DB. It is saved in managed metadata DB.

How should I copy the term set group towards the new farm? I cannot directly backup/restore the managed metadata DB because the destination DB contains termsets from other site collections and we should not override it. Also we don't have DB access.

If I export the termsets into CSV and import to new environment, the terms' GUID will be changed. Then I have to go over every library and list to fix the 100+ managed metadata column.

May I have your advice on this situation? Thanks.

Was it helpful?

Solution

I successfully did it by following this blog post:

Source SP Farm - Windows Azure SharePoint Server 2013 VM.

Destination SP Farm - SharePoint Server 2013 VM.

http://blog.kuppens-switsers.net/sharepoint/migrate-managed-metadata-between-farms/?subscribe=success#blog_subscription-3

Note: First migrate term store and then Backup/Restore site collection.

Finally Change site collection administrators of restored site collection from Central Administration (CA).

Here are detailed steps:

http://blog.kuppens-switsers.net/sharepoint/migrate-managed-metadata-between-farms/

Step 1 - Export Term Store script

$mmsApplication = Get-SPServiceApplication | ? {$_.TypeName -eq "Managed Metadata Service"}
$mmsProxy = Get-SPServiceApplicationProxy | ? {$_.TypeName -eq "Managed Metadata Service Connection"}
Export-SPMetadataWebServicePartitionData $mmsApplication.Id -ServiceProxy $mmsProxy -Path "C:\MMS\mmsdata.cab"

Step 2 - Import script

$mmsApplication = Get-SPServiceApplication | ? {$_.TypeName -eq "Managed Metadata Service"}
$mmsProxy = Get-SPServiceApplicationProxy | ? {$_.TypeName -eq "Managed Metadata Service Connection"}
Import-SPMetadataWebServicePartitionData $mmsApplication.Id -ServiceProxy $mmsProxy -Path "C:\MMS\mmsdata.cab" -OverwriteExisting

Step 3 - Backup site

Backup-SPSite -Identity "http://sp2103dev/sites/abc/" -Path "C:\MMS\sitetoarchive.bak"

Step 4 - Restore site

Restore-SPSite -Identity "http://sp2013/sites/xyz" -Path "C:\MMS\sitetoarchive.bak" -force

Step 5 - Note

After site restore we need to change site collection administrator(s) in Central Admin so that these users can access the site.

OTHER TIPS

Go for the export and import of the term set and then fix the existing items with a PowerShell script. The script should lookup the term in the term store given the text of an old term. Then it should assign the correct term with a new id. Hope it does make sense. I have a PowerShell script for that and if noone else posts an answer, I will upload it here once I get access to it (later in the day).

Your best bet is using powershell script to export and import the term set as Paul mentioned.

Here are script.

To Export

Add-PSSnapin Microsoft.SharePoint.Powershell
 $metadataApp= Get-SpServiceApplication | ? {$_.TypeName -eq "Managed Metadata Service"}
 $mmsAppId = $metadataApp.Id

 $mmsproxy = Get-SPServiceApplicationProxy | ?{$_.TypeName -eq "Managed Metadata Service Connection"}
 Export-SPMetadataWebServicePartitionData -Identity $mmsAppId -ServiceProxy $mmsproxy -Path "C:\Users\Desktop\MMD.cab”

To Import

Add-PSSnapin Microsoft.SharePoint.Powershell
 $metadataApp= Get-SpServiceApplication | ? {$_.TypeName -eq "Managed Metadata Service"}
 $mmsAppId = $metadataApp.Id

 $mmsproxy = Get-SPServiceApplicationProxy | ?{$_.TypeName -eq "Managed Metadata Service Connection"}

Import-SPMetadataWebServicePartitionData -Identity $mmsAppId -ServiceProxy $mmsproxy -Path "//SharedPath/Users/Desktop/MMD.cab" -OverwriteExisting;

Source: Migrating Managed Metadata Term Stores in SharePoint Server across Farms

Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top