How to Backup and Restore Companyweb in Small Business Server 2008

[Today’s post comes to us courtesy of Kunal Ghotge, Gagan Mehra, David Copeland, Justin Crosby, and Shawn Sullivan from Commercial Technical Support]

In this post, we will discuss options to backup and restore your SharePoint (Companyweb) site. A good backup and restore strategy is essential for maintaining business continuity when disaster happens.

Available Tools for backup


User Interface

Backup Type

Windows SharePoint Services: STSADM.exe

Command Line

Full and Differential

Windows SBS 2008 Backup


Full and Incremental

Windows SharePoint Services: Central Administration


Full and Differential


STSADM is a utility that is installed with SharePoint that allows you to perform administrative tasks on your SharePoint sites. By default, it is located in the following path: %ProgramFiles%\Common Files\Microsoft Shared\Web Server Extensions\12\BIN.

Note: You must run these commands from an elevated command prompt.

Backup Process

STSADM –o backup –url <SharePoint url> –filename <backup target file location> –overwrite

For example:
STSADM –o backup –url http://companyweb –filename “D:\backup\companyweb.bak” –overwrite

Restore Process

STSADM –o restore –url <SharePoint url> –filename <backup source file location> -overwrite

For example:
STSADM –o restore –url http://companyweb –filename “D:\backup\companyweb.bak” –overwrite

For more information on STSADM commands, see:


Using STSADM with Task Scheduler

Now that we have shown you how to backup SharePoint (Companyweb) using STADM, here is how to schedule those backups so that you always have an up to date backup.

  1. Create a script with the following content and save it as a .VBS file:

    dim dayweek
    dim strBackup
    dayweek = datepart("w",(date))
    strBackup = """C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN\stsadm""" +  "-o backup -url http://companyweb -filename x:\backups\companyweb" + cstr(dayweek) + ".dat -overwrite"
    Set WshShell = WScript.CreateObject("WScript.Shell")
    Return = WshShell.Run(strBackup, 0, true)
    Set WshShell = Nothing

    Important: Substitute x:\backups\companyweb for your desired backup location. You must create this directory before running the scheduled task or it will fail. 

  2. Launch the Task Scheduler
    1. Start –> Administrative Tools –>Task Scheduler.
    2. Click on Create Task in the Action Pane.
  3. Enter a name for the new task and choose Run whether user is logged on or not.


  4. Click on Actions tab and click on New... then ensure the following settings.
    Action: Start a Program
    Program/Script: CScript
    Arguments: Location of the script file which was saved earlier


  5. Click on Triggers tab and click New to define your backup schedule.


  6. Click OK.
  7. When it prompts for the password, provide your Administrator credentials.

Note: Make sure that the Administrator account that will run the task has the “Log on as batch job” user right. This can be done using the Group Policy settings. Additionally, when the password for the Administrator account changes in Active Directory, you must update the task with the new password.

Using Windows SBS 2008 Backup

You can also use Windows Small Business Server 2008 backup to backup and restore SharePoint (Companyweb). For information on how to configure Small Business Server 2008 backup to backup your server and SharePoint on a schedule, see:

Backup Now

Once SBS backup has been configured using the above link you will have the ability to create a backup immediately without having to wait for the schedule. To do this:

  1. Open the SBS Console and choose the Backup and Server Storage pane.
  2. Click on Backup now and click OK on the popup that appears.


    You will be notified once the backup is complete


Restoring Companyweb

  1. Open the SBS Console and choose the Backup and Server Storage pane
  2. Click the Restore server data from backup task
  3. Select the option to restore This server (Servername) and click Next.


  4. Select the date and time of the backup job you wish to restore and click Next.


  5. Under Select recovery type, choose Applications and click Next.


  6. Select Windows SharePoint Services. You can confirm the details by clicking on View Details. This will show you the files that will be restored.


  7. Choose the option to Recover to original location and click Next.


  8. Confirm the selected options and click Recover.


Once the restore finishes you will see a summary screen.


You can also use the SharePoint Central Administration site for backup and restore. However, we recommend using the above methods on Small Business Server 2008. For more information on the use of the SharePoint Central Administration site for backup and restore, please visit the following link: