SIGN UP MEMBER LOGIN:    
ARTICLE

Backup/Restore of a Sharepoint site

Posted by Ravish Sindhwani Articles | SharePoint June 15, 2010
In this article I will show you how to take backup of sharepoint site and restore it to another sharepoint site.
Reader Level:

In this article I will show you how to take backup of sharepoint site and restore it to another sharepoint site.  

In layman terms this backup and restore is just like copy and paste. Backup means taking copy of a sharepoint site and restore means paste to another.

There are two ways of doing this or we can say that two set of commands.
  • Backup - Restore
  • Import - Export
Both ways are having their own advantage and disadvantages.

In this article I will show you Backup and restore command.

To achieve this we will use STSADM utility. This utility is present in the below mentioned path.

C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\BIN

1.gif
 
I have created two web application. One is with some customization and other is blank site.

Website 1: Site with some customization having address http://spdevserver:1002/default.aspx 

2.gif
 
WebSite 2: Blank site having address http://spdevserver:1003/default.aspx 

3.gif
 
Now we will take the backup from http://spdevserver:1002/default.aspx and restore it to http://spdevserver:1003/default.aspx 

Steps to take site Backup:

Step 1:  Open Command prompt and go to location as shown in the below screenshot.

4.gif
 
Step 2: Write the STSADM command for taking the site backup.

stsadm -o backup -url http://spdevserver:1002/ -filename C:\Backup.bak

5.gif
 
This command will save Backup.bak file in C:\

This file is the complete backup for  http://spdevserver:1002/default.aspx

Now next step is to Restore this backup file to http://spdevserver:1003/default.aspx

To do this we need to write the STSADM command for Restore.

RESTORE COMMAND

stsadm -o restore -url http://spdevserver:1003/ -filename C:\Backup.bak -overwrite

6.gif
 
Now after completing this operation we are having  http://spdevserver:1003/default.aspx site which is exactly the replica of http://spdevserver:1002/default.aspx site.

Just refresh the page and you will see it.

7.gif
 
In this way we can take a backup of sharepoint site and restore it to another sharepoint site.

Login to add your contents and source code to this article
share this article :
post comment
 

Dotal,

The Backup and Restore works great but only for the top level sites. If you want to move/back up a subsite under a main site you need to use the export/import with stsadm.exe.

Posted by rob ingram Jun 17, 2010

Backup - Restore will take the root site collection only. It wont take all site collections.

Posted by Ravish Sindhwani Jun 16, 2010

Another question.


I tried it in a web application with several site collections, but only the default site collections was backed up. Is this correct?

In other words, must I repeat the backup proces for each site collection?

Thanks in advance.

Posted by David Otal Jun 16, 2010

Perfect. Thanks a lot!!!

Posted by David Otal Jun 16, 2010

Yes, It will restore all the lists, document library, items in Lists/Document Library, groups every thing which is associated with this web application in content database.

Posted by Ravish Sindhwani Jun 15, 2010
Nevron Gauge for SharePoint
Become a Sponsor
PREMIUM SPONSORS
  • ceTE software specializes in components for dynamic PDF generation and manipulation. The DynamicPDF™ product line allows you to dynamically generate PDF documents, merge PDF documents and new content to existing PDF documents from within your applications.
    Get 2 Months Free of ASP.NET Hosting for Only $4.95/month! Receive FREE MS SQL and MySQL Databases Including ASP.NET 4/3.5, MVC 3.0, Silverlight 4, Windows 2008/IIS 7.0 Plus FREE IIS 7 Modules. Host UNLIMITED ASP.NET Web Sites - Click Here!
Become a Sponsor