Export (0) Print
Expand All
Expand Minimize

Backing Up and Restoring Data

Archived content. No warranty is made as to technical accuracy. Content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Microsoft's SharePoint Team Services relies on a Microsoft SQL Server or Microsoft Data Engine (MSDE) database to store user and document information, and Web document discussion and Web subscription data. This database makes features like the document libraries and other lists possible. In addition, SharePoint Team Services relies on the file system to track documents and pages in the site.

Database information should be backed up on a regular basis to maintain a working Web site. The backup information is used to restore corrupted files, recover from a hard-disk crash, or roll back to a previous file version to repair a user mistake. With a Web site like a SharePoint team Web site, where your files and database information must be synchronized, the backup and restore process could get fairly difficult. However, SharePoint Team Services includes tools to back up and restore the database without requiring extensive SQL Server or Microsoft Windows NT experience.

When you back up the database, the backup file is automatically stored as webname.bak in the C:\MSSQL7\BACKUP directory. If you want to keep multiple backup files available, you must rename the files so that they are not overwritten.

You can back up and restore database information by using either HTML Administration pages or the command-line administration tools for SharePoint Team Services.

Note   Each virtual server has only one database, even though there may be multiple Web sites on that server. When you back up or restore the database, you do so for every Web site on the virtual server.

Because SharePoint Team Services relies on both the file system and a database to track information about your Web site, you must be sure to keep these systems synchronized. For example, a list in a SharePoint team Web site is a combination of data in the database and HTML files. If you want to back up a list, you must back up both the data in the database and the HTML files. SharePoint Team Services provides tools to use for backing up and restoring the collaboration database, but you must back up and restore the file system using your usual operating system tools. Be sure to back up the file system whenever you back up the database. Keeping your backups synchronized will help simplify the process if you ever need to restore your Web site.

Using HTML Administration Pages to Back Up and Restore Data

 Cc768008.spacer(en-us,TechNet.10).gif Cc768008.spacer(en-us,TechNet.10).gif

You can use HTML Administration pages to back up and restore the data in the database, and also to schedule automatic backups for regular intervals. To use these commands, you must have Administrator rights on the Web server computer.

Note   The SharePoint Timer Service is not available for FrontPage 2002 Server Extensions on the Windows Server 2003 family platform.

To create a database backup by using HTML Administration pages 

  1. On the server computer, click Start, point to Programs, point to Administrative Tools, and then click Microsoft SharePoint Administrator.

  2. On the Server Administration page, next to the virtual server that contains the data that you want to back up, click Administration.

  3. On the Virtual Server Administration page, click Backup and restore database.

  4. On the Backup and Restore Database page, in the Backup path and filename box, type the path and file name to store the backed up data in.

    For example, C:\MSSQL7\BACKUP\Webname.bak

  5. Click Backup.

You can restore the database backup from the same Database Backup and Restore page.

To restore a database backup by using HTML Administration pages 

  1. Open the Virtual Server Administration page that contains the data that you want to restore.

  2. Click Backup and restore database.

  3. On the Backup and Restore Database page, in the Restore path and filename box, type the path and filename to use.

    For example, C:\MSSQL7\BACKUP\Webname.bak

  4. Click Restore.

You can also schedule an automatic backup of your database from the Schedule Database Backup administration page.

To automatically back up the database 

  1. On the server computer, click Start, point to Programs, point to Administrative Tools, and then click Microsoft SharePoint Administrator.

  2. On the Server Administration page, next to the virtual server that contains the data that you want to back up, click Administration.

  3. On the Virtual Server Administration page, click Schedule database backup.

  4. Next to Automatic database backups are, select On.

  5. Under Automatic database backups occur, select Daily, Weekly, or Monthly.

  6. If you selected Daily, in the Time box, select the time of day to perform the backup.

    – or –

    If you selected Weekly, in the Time box, select the time of day, and then in the Weekday box, select the day of the week to perform the backup.

    – or –

    If you selected Monthly, in the Day box, select the day of the month, and then in the Time box, select the time of the day to perform the backup.

  7. Click Submit.

Using the Command-Line Tools to Back Up and Restore Data

 Cc768008.spacer(en-us,TechNet.10).gif Cc768008.spacer(en-us,TechNet.10).gif

You can use the command line to back up and restore the database either locally, by using Owsadm.exe, or remotely, by using Owsrmadm.exe. To back up the database from the command line, you use the BackupDB operation. To restore, you use RestoreDB. The BackupDB operation takes the optional parameters –filename, -port, and –schedule. To do a simple backup of the database on port 80, you would use the following syntax:

Owsadm.exe –o backupdb –p 80 –f path/filename

The RestoreDB operation takes the optional –filename and –port parameters. To perform a simple restore of the same database, you would use the following syntax:

Owsadm.exe –o restoredb –p 80 –f path/filename

You can also back up the database automatically, by creating a scheduled job for the backup process. To schedule automatic backup you use the BackupDB operation with the schedule parameter, and specify a time/day/month/year to back up the database.

Note   The SharePoint Timer Service is not available for FrontPage 2002 Server Extensions on the Windows Server 2003 family platform. For that environment, you must back up the database manually, rather than scheduling automatic backups. If you want to automate the backup process, you can do so by including the backup command-line string in a batch file or script.

The following example syntax shows how to set the database to be backed up every Monday at 11:59 P.M. for port 80.

owsadm –o backupdb –p 80 –schedule "weekly at Mon 23:59"

For more information about specifying the times to use for backing up the database, see Scheduling Timed Jobs.

Cc768008.spacer(en-us,TechNet.10).gif

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft