Back up a site collection (SharePoint Foundation 2010)
Published: May 12, 2010
This article describes how to back up an individual site collection. We recommend that you regularly back up the complete farm. However, IT practices might require that you also back up a site collection. For more information about what to back up, see Plan for backup and recovery (SharePoint Foundation 2010).
If the site collection’s Lock status is set to Not locked or Adding content prevented, Microsoft SharePoint Foundation 2010 temporarily sets the site to Read-Only while the backup operation is occurring. SharePoint Foundation 2010 does this to reduce the possibilities of users changing the site collection while it is being backed up. After the backup is finished, the setting is changed back its normal status.
Performing a site collection backup might require resources and might slightly affect farm performance when the backup is running. You can help avoid performance issues by backing up the farm during hours when farm use is lowest, such as outside office hours.
Procedures in this task:
Before you begin, you must create a folder on the local computer or the network in which to store the backups. For better performance, we recommend that you back up to the local computer and then move the backup files to a network folder. For more information about how to create a backup folder, see Prepare to back up and recover (SharePoint Foundation 2010).
Use Windows PowerShell to back up a site collection
You can use Windows PowerShell to back up a site collection manually or as part of a script that can be run at scheduled intervals.
To back up a site collection by using Windows PowerShell
Verify that you meet the following minimum requirements: See Add-SPShellAdmin.
On the Start menu, click All Programs.
Click Microsoft SharePoint 2010 Products.
Click SharePoint 2010 Management Shell.
At the Windows PowerShell command prompt type the following command:
Backup-SPSite -Identity <Site collection name> -Path <backup file> [-Force] [-NoSiteLock] [-UseSqlSnapshot] [-Verbose]
You must use the exact name for the site collection that you are backing up with Windows PowerShell. To find the site collection name in Central Administration click Application Management and in the Site Collections section, click View all site collections.
If you want to overwrite a previously used backup file, use the
Forceparameter. You can use the
NoSiteLockparameter to keep the read-only lock from being set on the site collection while it is being backed up. However, using this parameter can allow users to change the site collection while it is being backed up and might lead to possible data corruption during backup.
If the database server is running an Enterprise Edition of Microsoft SQL Server, we recommend that you also use the
UseSqlSnapshotparameter for more consistent backups. You can also export sites or lists from these snapshots.
Applies to environments that have not been updated to Service Pack 1 - When you perform a backup that uses the
UseSqlSnapshotparameter, a backup will be completed successfully. However, you will see an error similar to the following:
Backup-SPSite : Operation is not valid due to the current state of the object.
At line:1 char:14+ Backup-SPSite <<<< http://site -Path + CategoryInfo : NotSpecified: (:) [Backup-SPSite], InvalidOperationException + FullyQualifiedErrorId : System.InvalidOperationException,Microsoft.SharePoint.PowerShell.SPCmdletBackupSite\\yourpath
If the RBS provider that you are using does not support snapshots, you cannot use snapshots for content deployment or backup. For example, the SQL FILESTREAM provider does not support snapshots.
For more information about using SQL snapshots, see Back up databases to snapshots (SharePoint Foundation 2010).
For more information, see Backup-SPSite.
We recommend that you use Windows PowerShell when performing command-line administrative tasks. The Stsadm command-line tool has been deprecated, but is included to support compatibility with previous product versions.
Use Central Administration to back up a site collection
You can use Central Administration to back up a site collection.
To back up a site collection by using Central Administration
Verify that the user account performing this procedure is a member of the Farm Administrators group. Additionally, verify that the Windows SharePoint Services Timer V4 service has Full Control permissions on the backup folder.
In Central Administration, on the Home page, in the Backup and Restore section, click Perform a site collection backup.
On the Site collection backup page, select the site collection from the Site Collection list.
Type the local path of the backup file in the Filename box.
If you want to reuse a file, select the Overwrite existing file check box.
Click Start Backup.
You can view the general status of all backup jobs at the top of the Granular Backup Job Status page in the Readiness section. You can view the status for the current backup job in the lower part of the page in the Site Collection Backup section. The status page updates every 30 seconds automatically. You can manually update the status details by clicking Refresh. Backup and recovery are Timer service jobs. Therefore, it may take several seconds for the backup to start.
If you receive any errors, you can review them in the Failure Message column of the Granular Backup Job Status page.