Automating Site Collection Backup and Restore
To perform a backup of an individual site collection, type the following:
Backup-SPSite "http://portal.companyABC.com" –path "C:\Backups\portal.dat" -force
The command in the preceding example backs up a site collection at the given url to the designated path. Before running this cmdlet, make sure this path (for example, C:\Backup
) exists. In case there is a previous backup file at this location, use the –force
parameter to overwrite an existing backup file.
To restore the site collection, type the following:
There are two parameters that must be used for silent site collection restore. -force
ensures ...
Get Microsoft SharePoint 2010 Unleashed now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.