In this post I will provide the steps to move a SharePoint 2010 on premises subsite within the same site-collection .
This process is considered easy in SharePoint 2010 but I would point out some protective steps that will allow you a rollback if something bad happened while moving the site.
The initial requirement is to change a subsite location within a site collection hierarchy. This is a simple requirement, since SharePoint 2010 do provide a GUI tool for this task. However, moving a website can be a dangerous action and I prefer using the copy and delete method rather then moving the file , the option of copying the subset provides addition protection since it provides the ability to rollback at any stage to the original state, and prevent any downtime for the end-user.
The high level steps :
- Preparation – understanding the scope of this change.
- Backup the subsite
- Moving the subsite with copying the subsite and then deleting.
- Things to notice.
This is true both for your own SharePoint website, but it’s much more important when you are working on a bigger scale for example a company’s SharePoint farm. when you work on a sharpoint farm with a lot of site collections and subsites, the data on the subsite is not yours and can be very sensitive. At this stage when you just receive the request to move the site, you need to ask the following questions in order to assess the effort and evaluate the risks.
- Evaluate the site of the site you want to move. ( is there any limitation when moving big sites).
- Understand the reason for moving the site. In some cases the user reason can trigger a creation of a new site collection with a dedicated content database for example.
- Log relevant information on the website including :
- Number of lists
- Number of document libraries
- Third party objects, for example Nintex Forms or Workflows.
- Security structure and does it break the destination security hierarchy
- Document the information collected as part of your farm changes tracking system, which might be a dedicated running list within SharePoint.
Backup the subsite
Backup the subsite in a big environment of hundreds of other websites in a SharePoint farm , will minimize the potential of data lost when you moving your site. It also provides you with a recovery plan if you ever need to rollback your changes.
- Using your farm/site system account RDP the application server.
- Create or use a dedicated folder to store SharePoint site backups [backup file location].
- Open windows PowerShell ISE
- Copy paste the following command onto the ISE.
|stsadm -o export -url http://[your site url] -filename “[backup file location]” -includeusersecurity -versions 4|
5. Validate the backup file in the target backup folder.
Moving the Subsite
Using the SharePoint 2010 GUI – go to site settings and select Content and Structure
Select the site you want to copy, make sure you are picking a site and not a Document Library or a List.
After the subsite copied, and the end-user approved the change, you can delete the old subsite. This provides you with another protection since the site is being send to the site recycle bin, and If needed you will be able to restore the site from the site recycle bin or the site collection recycle bin, depending on how long since the site originally deleted.