Thursday, November 29, 2012

How to restore SharePoint 2013 Content Database


In my previous post I have shared about SharePoint 2013 content database backup. To restore SharePoint Content Database we can select any option out of three in SharePoint 2013: SharePoint Central Administration, Windows PowerShell, SQL Server tools. Here are steps to restore SharePoint 2013 Content Database:

Windows PowerShell:

Before using Windows Powershell, ensure that you have securityadmin, db_owner, Administrators group memberships. 

1. Start the SharePoint 2013 Management Shell by using following path:

Start>>All Programs>>Microsoft SharePoint 2013 Products>> SharePoint 2013 Management Shell.

2. Type following command on Windows PowerShell command prompt:

Restore-SPFarm -Directory <BackupFolder> -RestoreMethod Overwrite -Item <ContentDatabaseName> [-BackupId <GUID>] [-Verbose]

Here <BackupFolder> is the name and path for the backup folder & <ContentDatabaseName>is the name of the content database.

SharePoint Central Administration: 

Before using this method, first make sure that the user who is performing the procedure should have member of Farm Administrators SharePoint group.

1. Start SharePoint 2013 Central Administration.

Start>>Microsoft SharePoint 2013 Products>>SharePoint 2013 Central Administration

2. In Backup and Restore section>>Restore from backup>>select backup that you want to restore (select same backup job that content database backup have)>>click 'Next'.

3. In 'Restore Option' Section>> click same configuration option.

4. Click Start Restore.

SQL Server tools: 

Before using SQL Server tools, first you should verify that the user that is going to perform the procedure should be member of sysadmin. 

1. Open SQL Server Management Studio
2. After that connect to the database server.
3. Object Explorer>>expand Databases.
4. Right-click the database that you want to restore>>Tasks>>Restore>>database.
5. Restore Database>>specify the destination>>select the backup that you want to restore.
6. Select a page pane, click Options.
7. Restore options>>Overwrite the existing database.
8. Recovery state

  •  Use RECOVER WITH RECOVERY option if you want to restore all the transaction logs.
  •  Use RECOVER WITH NORECOVERY option if you want to restore additional transaction logs.


9. Click OK to complete your recovery process. 

Hope the steps will help you to successfully restore SharePoint Content database. 

No comments:

Post a Comment