The steps taken during the preparation of the migration process are below:
1. Setup and configure the new SharePoint farm
2. Deploy non out of the box site templates if any (e.g. F40 application templates) in the new farm
3. Create staging web application in the new farm
4. Create destination web application in the new farm
The steps taken during the actual migration process are below:
1. Set the root site collection in the old farm to read only mode to prevent any new updates
stsadm -o setsitelock -url {root_site_collection_url}
2. Copy the content database backup file of the old farm to the new farm's database server and restore it
3. Attach the restored content database to the staging web application in the new farm
stsadm -o addcontentdb -url {web_application_url}
4. Export the fourteen sites of the root site collection in the staging web application to files in the file system
stsadm -o export -url {site_url} -filename {file_path_and_name} -overwrite -includeusersecurity -versions 4 -cabsize 100
Notes:
includeusersecurity: preserves the user security settings
versions: indicates which type of file and list item version history should be included in the export. If the -versions parameter is absent, the export operation will default to using a value of 1.
1: Last major version for files and list items(default)
2: The current version, either the last major or the last minor
3: Last major and last minor version for files and list items
4: All versions for files and list items
cabsize: An integer from 1 to 1024 megabytes that describes how large each cabinet file (*.cab) should be. Once the specified size is reached, another cabinet file is generated. This can be beneficial if you are copying files over a network, and you want the file size to be small.
For example:
- stsadm -o export -url http://oldportal.contoso.com/marketing -filename D:\SharePointSiteExport\Marketing\Marketing.exp -overwrite -includeusersecurity -versions 4 -cabsize 100
- stsadm -o export -url http://oldportal.contoso.com/sales -filename D:\SharePointSiteExport\Sales\Sales.exp -overwrite -includeusersecurity -versions 4 -cabsize 100
5. Create fourteen new site collections with their own dedicated content databases using Blank site template in the new farm
stsadm -o createsiteinnewdb -url {site_collection_url} -ownerlogin {owner_login_id} -ownername {owner_name} -owneremail {owner_email} -sitetemplate "STS#1" - title {site_collection_title} -description {site_collection_description} -quota {quota_template} -databasename {database_name} -databaseserver {database_instance_name}
stsadm -o createsiteinnewdb -url {site_collection_url} -ownerlogin {owner_login_id} -ownername {owner_name} -owneremail {owner_email} -sitetemplate "STS#1" - title {site_collection_title} -description {site_collection_description} -quota {quota_template} -databasename {database_name} -databaseserver {database_instance_name}
For example:
- stsadm -o createsiteinnewdb -url http://newportal.contoso.com/sites/Marketing -ownerlogin "contoso\davidlim" -ownername "Lim, David" -owneremail "davidlim@contoso.com" -sitetemplate "STS#1" -title "Marketing Site" -description "Contoso Marketing Site" -quota "Contoso Quota" -databasename "Contoso_Content_Marketing" -databaseserver "CONTOSOSQL"
- stsadm -o createsiteinnewdb -url http://newportal.contoso.com/sites/Sales -ownerlogin "contoso\davidlim" -ownername "Lim, David" -owneremail "davidlim@contoso.com" -sitetemplate "STS#1" -title "Sales Site" -description "Contoso Sales Site" -quota "Contoso Quota" -databasename "Contoso_Content_Sales" -databaseserver "CONTOSOSQL"
stsadm -o import -url {site_collection_url} -filename {file_path_and name} -includeusersecurity -updateversions 2
Notes:
updateversions: indicates how to resolve situations where a file to be imported to a site already exists in that site. If the -updateversions parameter is absent, the import operation will default to using a value of 1
1: Add new versions to the current file (default)
2: Overwrite the file and all of its versions (delete then insert)
3: Ignore the file if it exists on the destination
For example:
- stsadm -o import -url http://newportal.contoso.com/sites/Marketing -filename D:\SharePointSiteExport\Marketing\Marketing.exp -includeusersecurity -updateversions 2
- stsadm -o import -url http://newportal.contoso.com/sites/Sales -filename D:\SharePointSiteExport\Sales\Sales.exp -includeusersecurity -updateversions 2
Nice, article. Knowing about setsitelock was interesting. Can you add some more details for configuration database as well? We followed MS guidelines but WFE cache is out of synch
ReplyDeleteI absolutely love your blog and find nearly all of your post’s to be precisely what I’m looking for.
ReplyDeleteSharePoint 2013 Administration training Online