Search This Blog

Sunday, November 15, 2015

Backup and Restore SharePoint Site using Shell Command


Backup SharePoint Site Shell Command:
Backup-SPSite http://sitename -Path E:\Backup\site_name.bak

Description:
The Backup-SPSite cmdlet performs a backup of the site
collection when the Identity parameter is used. By default, the site collection
will be set to read-only for the duration of the backup to reduce the potential
for user activity during the backup operation to corrupt the backup.

Restore a SharePoint site Shell Command:
Restore-SPSite http://sitename -Path "E:\Backup\file.bak" -Force

Restore a SharePoint site to a specific database Shell Command:
Restore-SPSite http://sitename -Path "E:\Backup\file.bak" -Force -DatabaseName "Database"

Description:
The Restore-SPSite cmdlet performs a restoration of the
site collection to a location specified by the Identity parameter. A content
database may only contain one copy of a site collection. If a site collection
is backed up and restored to a different URL location within the same Web
application, an additional content database must be available to hold the
restored copy of the site collection.

No comments:

Post a Comment

Restricting Custom People Picker to only one Sharepoint group programatically

Refer the following script files in your page,     <!-- For People Picker -->     <script type="text/javascript" src...