Share via

How to Back Up and Recover a Client Access Server

Microsoft Exchange Server 2007 will reach end of support on April 11, 2017. To stay supported, you will need to upgrade. For more information, see Resources to help you upgrade your Office 2007 servers and clients.


Applies to: Exchange Server 2007, Exchange Server 2007 SP1, Exchange Server 2007 SP2, Exchange Server 2007 SP3

This topic explains how you can use the Exchange Management Shell to back up and restore the Internet Information Services (IIS) metabase data that a Client Access server uses to store Microsoft Office Outlook Web Access Virtual Directory configuration data.


The script and procedure included in this topic is an example of one possible way to complete this task. Before you use these techniques in a production environment, test them in a lab environment.

Before You Begin

To perform the following procedures, the account you use must be delegated the Exchange Server Administrator role and local Administrators group for the target server. For more information about permissions, delegating roles, and the rights that are required to administer Microsoft Exchange Server 2007, see Permission Considerations.

Before you can perform this example restore procedure, you must create a script in the Exchange \bin folder that is similar to the following example:

$ErrorActionPreference = 'stop'
$savedprops = @(

$vdir = import-clixml $args[0]

'Recreating "' + $ + '"' + ' owa version: ' + $vdir.owaversion
if ($vdir.owaversion -eq 'Exchange2007') {
new-owavirtualdirectory -website $ -internalurl $vdir.internalurl -externalurl $vdir.externalurl
else {
new-owavirtualdirectory -website $ -owaversion $vdir.owaversion -name $vdir.displayname -virtualdirectorytype $vdir.virtualdirectorytype
$new = get-owavirtualdirectory $
'Restoring properties'
foreach ($prop in $savedprops) {
if ($prop -eq 'ExchwebProxyDestination' -or $prop -eq 'VirtualDirectoryType') {
$new.$prop = $vdir.$prop
$new | set-owavirtualdirectory


In the following procedure, this script is named restorevdir.ps1.


To back up the IIS configuration of a Client Access server

  • Run the following Exchange Management Shell command:

    get-owavirtualdirectory "owa (default web site)" | export-clixml owa.xml -depth 1

To restore the IIS configuration of a Client Access server

  • Run the following Exchange Management Shell command:

    restorevdir.ps1 owa.xml

For More Information

For more information about the data that needs to backed up on a Client Access server, see Client Access Server Data.