Поделиться через


New-DPMRecoveryOption

New-DPMRecoveryOption

Creates recovery options.

Syntax

Parameter Set: ClientDatasourceRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -ClientDatasource -OverwriteType <OverwriteType> {Overwrite | NoOverwrite | CopyOnExist} -RecoveryType <RecoveryType> {Recover | Restore} [-AlternateLocation <String> ] [-DPMLibrary <Library> ] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-SANRecovery] [ <CommonParameters>]

Parameter Set: E14RecoveryOption
New-DPMRecoveryOption [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} [-TargetServer] <String> -E14Datasource -ExchangeOperationType <ExchangeBaseRecoveryOptions+ExchangeOperationType> {NoOperation | MailBoxLevelRecovery | NeedCleanShutdown} -RecoveryType <RecoveryType> {Recover | Restore} [-AlternateDatabase <String> ] [-DPMLibrary <Library> ] [-IsRecoveryDatabase] [-MountDatabaseAfterRestore] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-RollForwardRecovery] [-SANRecovery] [-TargetLocation <String> ] [ <CommonParameters>]

Parameter Set: ExchangeRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -Exchange -ExchangeOperationType <ExchangeBaseRecoveryOptions+ExchangeOperationType> {NoOperation | MailBoxLevelRecovery | NeedCleanShutdown} -RecoveryType <RecoveryType> {Recover | Restore} [-AlternateDatabase <String> ] [-AlternateStorageGroup <String> ] [-DatabaseName <String> ] [-DPMLibrary <Library> ] [-IsRecoveryStorageGroup] [-MailboxDisplayName <String> ] [-MountDatabaseAfterRestore] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-RollForwardRecovery] [-SANRecovery] [-StorageGroupName <String> ] [-TargetLocation <String> ] [ <CommonParameters>]

Parameter Set: FsRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -FileSystem -OverwriteType <OverwriteType> {Overwrite | NoOverwrite | CopyOnExist} -RecoveryType <RecoveryType> {Recover | Restore} [-AlternateLocation <String> ] [-DPMLibrary <Library> ] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-SANRecovery] [ <CommonParameters>]

Parameter Set: GenericDatasourceRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -GenericDatasource -RecoveryType <RecoveryType> {Recover | Restore} [-DPMLibrary <Library> ] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-SANRecovery] [-TargetLocation <String> ] [ <CommonParameters>]

Parameter Set: HyperVDatasourceRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -HyperVDatasource -RecoveryType <RecoveryType> {Recover | Restore} [-DPMLibrary <Library> ] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-SANRecovery] [-TargetLocation <String> ] [ <CommonParameters>]

Parameter Set: RecoverToDpm
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -PrimaryDpmServer [-DPMLibrary <Library> ] [-RecoverToReplicaFromTape <Boolean> ] [ <CommonParameters>]

Parameter Set: SharePointRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -RecoveryType <RecoveryType> {Recover | Restore} -SharePoint [-DPMLibrary <Library> ] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-SANRecovery] [-TargetLocation <String> ] [ <CommonParameters>]

Parameter Set: SharePointSiteRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -DatabaseFileTempLocation <String> -ExportFileTempLocation <String> -IntermediateServer <String> -IntermediateSqlInstance <String> -RecoveryType <RecoveryType> {Recover | Restore} -SharePointSite [-DPMLibrary <Library> ] [-ItemLevelRecoveryType <SharepointRecoveryType> {RecoveryFarm | UnattachedInstance} ] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-SANRecovery] [-TargetLocation <String> ] [-TargetSiteUrl <String> ] [ <CommonParameters>]

Parameter Set: SQLRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -RecoveryType <RecoveryType> {Recover | Restore} -SQL [-AlternateDatabaseDetails <AlternateDatabaseDetailsType> ] [-CopyLogFiles] [-DPMLibrary <Library> ] [-LeaveDBInRestoringState] [-LogFileCopyLocation <String> ] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-RollForwardRecovery] [-SANRecovery] [-TargetLocation <String> ] [ <CommonParameters>]

Parameter Set: StagingAreaRestoreOption
New-DPMRecoveryOption [[-DPMServerName] <String> ] [-StagingAreaPath] <String> [-DestinationServerName] <String> [-DestinationPath] <String> [-DatasourceName] <String> [-OverwriteType] <OverwriteType> {Overwrite | NoOverwrite | CopyOnExist} [[-RestoreSecurity]] -DPMComponentName <Guid> [-DPMLibrary <Library> ] [-FileSystemDatasource] [-RecoverToReplicaFromTape <Boolean> ] [ <CommonParameters>]

Parameter Set: SystemProtectionRecoveryOption
New-DPMRecoveryOption [-TargetServer] <String> [-RecoveryLocation] <DbEnums+RecoveryLocation> {OriginalServer | CopyToFolder | OriginalServerWithDBRename | AlternateExchangeServer | ExchangeServerDatabase | PrimaryDPMServer | DPMReplicaVolume | AlternateHyperVServer} -RecoveryType <RecoveryType> {Recover | Restore} -SystemProtectionDatasource [-DPMLibrary <Library> ] [-RecoverToReplicaFromTape <Boolean> ] [-RestoreSecurity] [-SANRecovery] [-TargetLocation <String> ] [ <CommonParameters>]

Parameter Set: VMWareVMRecoveryToAlternateLocOption
New-DPMRecoveryOption -VMWareTargetDatastore <VMWareDatastore> -VMWareTargetFolder <VMWareFolder> -VMWareTargetHost <VMWareHostSystem> -VMWareTargetResourcePool <VMWareResourcePool> -VMwareVM [-VMWareStoragePath <String> ] [ <CommonParameters>]

Parameter Set: VMWareVMRecoveryToOriginalLocOption
New-DPMRecoveryOption -VMwareVM [ <CommonParameters>]

Parameter Set: VMWareVMRestoreToFolderOption
New-DPMRecoveryOption -VMwareVM [ <CommonParameters>]

Detailed Description

The New-DPMRecoveryOption cmdlet creates recovery options for file servers, computers that run Exchange Server, SharePoint Server, and Microsoft SQL Server, and other data sources.

Parameters

-AlternateDatabase<String>

Specifies the name of an alternate database for recovery.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-AlternateDatabaseDetails<AlternateDatabaseDetailsType>

Specifies the type of the alternate database.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-AlternateLocation<String>

Specifies an alternate location where DPM creates a recovery point.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-AlternateStorageGroup<String>

Specifies an alternate storage group for a new recovery point.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ClientDatasource

Indicates that the restored data is a file system or an application.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-CopyLogFiles

Indicates that DPM copies the log files.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DatabaseFileTempLocation<String>

Specifies a temporary location for the database file.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DatabaseName<String>

Specifies the name of the database.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DatasourceName<String>

Specifies the name of the data source.

Aliases

none

Required?

true

Position?

5

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DestinationPath<String>

Specifies the recovery location.

Aliases

none

Required?

true

Position?

4

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DestinationServerName<String>

Specifies the name of the server to which DPM recovers data.

Aliases

none

Required?

true

Position?

3

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DPMComponentName<Guid>

Specifies the GUID of the data source that DPM recovers.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DPMLibrary<Library>

Specifies a DPM library object for which this cmdlet creates a recovery option. To obtain a DPM library object, use the Get-DPMLibrary cmdlet.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DPMServerName<String>

Specifies the name of a DPM server on which this cmdlet acts. If you do not specify a name, the cmdlet uses the name of the current computer.

Aliases

none

Required?

false

Position?

1

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-E14Datasource

Indicates that the data source is Exchange Server 2010.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Exchange

Indicates that DPM performs the current operation on a Exchange Server data source.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ExchangeOperationType<ExchangeBaseRecoveryOptions+ExchangeOperationType>

Specifies the type of operation that DPM performs on a Exchange Server data source. Valid values are:

-- NoOperation
-- MailBoxLevelRecovery
-- NeedCleanShutdown

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ExportFileTempLocation<String>

Specifies the location of the export file.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-FileSystem

Indicates that DPM performs the current operation on a file system data source.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-FileSystemDatasource

Indicates that DPM recovers a file system data source.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-GenericDatasource

Indicates that DPM performs the current operation on a data source such as Microsoft Virtual Server.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-HyperVDatasource

Indicates that the data source is Hyper-V.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-IntermediateServer<String>

Specifies the server that DPM uses for SharePoint site recovery.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-IntermediateSqlInstance<String>

Specifies an instance of SQL Server that DPM uses for SharePoint site recovery. DPM uses the instance of SQL Server to temporarily host a SQL Server database.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-IsRecoveryDatabase

Indicates that the database is a recovery database.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-IsRecoveryStorageGroup

Indicates that the recovery is a recovery storage group.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ItemLevelRecoveryType<SharepointRecoveryType>

Specifies the recovery type. Valid values are:

-- RecoveryFarm
-- UnattachedInstance

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-LeaveDBInRestoringState

Indicates that DPM leaves the database non-operational but in a restorable state. Specify this parameter to leave the database operational.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-LogFileCopyLocation<String>

Specifies the location where DPM copies log files.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-MailboxDisplayName<String>

Specifies a name that DPM displays on the mailbox.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-MountDatabaseAfterRestore

Indicates that DPM mounts the database after it restores the database.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-OverwriteType<OverwriteType>

Specifies the action that DPM takes when the file it is recovering already exists. Valid values are:
-- CreateCopy
-- Skip
-- Overwrite

Aliases

none

Required?

true

Position?

6

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-PrimaryDpmServer

Indicates that the server where DPM recovers data is a DPM server.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RecoverToReplicaFromTape<Boolean>

Indicates whether recovery to the replica is from a tape.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RecoveryLocation<DbEnums+RecoveryLocation>

Specifies the location where DPM recovers data. Valid values are:
-- OriginalServer
-- CopyToFolder
-- OriginalServerWithDBRename
-- AlternateExchangeServer
-- ExchangeServerDatabase

Aliases

none

Required?

true

Position?

2

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RecoveryType<RecoveryType>

Specifies the recovery type. If you specify the HyperVDatasource parameter, the only valid value is Recover. Valid values are: Recover or Restore.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RestoreSecurity

Indicates that DPM uses the security settings from the recovery point. If you do not specify this parameter, DPM uses the security settings of the destination server.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RollForwardRecovery

Indicates that DPM recovers the application from the latest recovery point and applies all logs after that recovery point to bring the application to the latest state.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SANRecovery

Indicates that DPM performs the current operation on a Storage Area Network (SAN) data source.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SharePoint

Indicates that DPM performs the current operation on a SharePoint data source.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SharePointSite

Indicates that DPM performs the current operation on a SharePoint site.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SQL

Indicates that DPM performs the current operation on a SQL Server data source.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-StagingAreaPath<String>

Specifies the path of the staging area.

Aliases

none

Required?

true

Position?

2

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-StorageGroupName<String>

Specifies the name of the storage group.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SystemProtectionDatasource

Indicates that DPM performs the current operation on a system protection data source.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-TargetLocation<String>

Specifies the location where DPM stores the replica.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-TargetServer<String>

Specifies the target server for recovery.

If you use this cmdlet in a clustered environment, specify the target server parameter in the format ResourceGroupName.ClusterName.DomainName.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-TargetSiteUrl<String>

Specifies the URL of the target where DPM recovers data.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VMWareStoragePath<String>

Specifies the VMware storage path.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VMWareTargetDatastore<VMWareDatastore>

Specifies the target VMware datastore.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VMWareTargetFolder<VMWareFolder>

Specifies the target VMware folder.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VMWareTargetHost<VMWareHostSystem>

Specifies the target VMware host.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VMWareTargetResourcePool<VMWareResourcePool>

Specifies the target VMware resource pool.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VMwareVM

Specifies a VMware virtual machine.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

  • RecoveryOption

Examples

Example 1: Recover a file system

This command creates a recovery option that restores the file system to tsqa.contoso.com and restores the original security settings.

PS C:\> New-DPMRecoveryOption -TargetServer "tsqa.contoso.com" -RecoveryLocation "D:\copytofolder" -FileSystem -AlternateLocation "F:\restore" -OverwriteType Overwrite -RestoreSecurity -RecoveryType Restore

Example 2: Recover a file system by using a replica

The first command opens a connection to a DPM server.

The second command gets the computer named DPMServer01. The DPM protection agent is installed on this server. The command stores the server in the $PServer variable.

The third command gets the list of protected and unprotected data on the protection server in $PServer. The command stores the result in the $PObject variable.

The fourth command gets the libraries associated with the DPM server named DPoreMServer01. The command stores the libraries in the $DpmLibrary variable.

The fifth command gets the recovery point for the data source in $PObject, and then stores that recovery point result in the $RPoint variable.

The sixth command creates a recovery option on a file system data source. The command specifies that data is recovered to the replica on the target server named DPMServer02 from a tape.

PS C:\> Connect-DPMServer -DPMServerName "DPMServer01"
PS C:\> $PServer = Get-DPMProductionServer -DPMServerName "DPMServer01"
PS C:\> $PObjects = Get-DPMDatasource -ProductionServer $PServer
PS C:\> $DpmLibrary = Get-DPMLibrary -DPMServerName "DPoreMServer01"
PS C:\> $RPoint = Get-DPMRecoveryPoint -Datasource $PObjects
PS C:\> $ROption = New-DPMRecoveryOption -Filesystem -RecoverToReplicaFromTape $True -RecoveryLocation DPMReplicaVolume -DPMLibrary $DpmLibrary[0] -TargetServer "DPMServer02" -OverwriteType Overwrite

Example 3: Recover a file system from a replica on tape

The first command gets the protection group on the DPM server named DPMServer02. The command stores the result in the $PGroup variable.

The second command gets the protected and unprotected data on the production server in $PServer. The command stores the results in the $PObject variable.

The third command gets the recovery point for the data source in $PObject, and stores that recovery point in the $RPoint variable.

The fourth command gets the libraries associated with the DPM server named DPoreMServer01. The command stores the libraries in the $DpmLibraries variable.

The fifth command creates a recovery option on a file system data source. The command specifies that data is recovered to the replica on the target server named DPMServer02 from a tape.

The sixth command restores a version of the data source in $RPoint by using the recovery option in $ROption.

PS C:\> $PGroup = Get-DPMProtectionGroup -DPMServerName "DPMServer02"
PS C:\> $PObject = Get-DPMDatasource -ProductionServer $PGroup
PS C:\> $RPoint = Get-DPMRecoveryPoint -Datasource $PObject
PS C:\> $DpmLibraries = Get-DPMLibrary -DPMServerName "DPoreMServer01"
PS C:\> $ROption = New-DPMRecoveryOption -RecoverToReplicaFromTape $True -RecoveryLocation DPMReplicaVolume -FileSystem -TargetServer "DPMServer02" -OverwriteType Overwrite -RecoveryType Recover -DpmLibrary $DpmLibraries
PS C:\> Restore-DPMRecoverableItem -RecoverableItem $RPoint -RecoveryOption $ROption

Example 4: Recover a VMware virtual machine using Original Location Recovery

The first command gets the protection group on the DPM server named DPMServer02. The command stores the result in the $PGroup variable.

The second command gets the protected and unprotected data on the production server in $PServer. The command stores the results in the $PObject variable.

The third command gets the recovery point for the data source in $PObject, and stores that recovery point in the $RPoint variable.

The fourth command creates a recovery option on a VMware virtual machine datasource. The command specifies that data is recovered from replica to VMware virtual machine.

The fifth command restores a version of the data source in $RPoint by using the recovery option in $ROption.

PS C:\> $PGroup = Get-DPMProtectionGroup -DPMServerName "DPMServer02"
PS C:\> $PObject = Get-DPMDatasource -ProductionServer $PGroup
PS C:\> $RPoint = Get-DPMRecoveryPoint -Datasource $PObject
PS C:\> $ROption = New-DPMRecoveryOption -VMwareVM -TargetServer "VCenterServer" 
PS C:\> Restore-DPMRecoverableItem -RecoverableItem $RPoint -RecoveryOption $ROption

Example 5: Recover a VMware virtual machine using Alternate Location Recovery

The first command gets the protection group on the DPM server named DPMServer02. The command stores the result in the $PGroup variable.

The second command gets the protected and unprotected data on the production server in $PServer. The command stores the results in the $PObject variable.

The third command gets the recovery point for the data source in $PObject, and stores that recovery point in the $RPoint variable.

The fourth command gets the DPM production server, and stores it in the $PS.

The fifth command gets the VMware inventory, and then stores it in the $Inventory variable.

The sixth command gets the specified folder, and then stores it in the $Folder variable.

The seventh command gets the specified host, and then stores it in the $Host variable.

The eigth command gets the specified data store, and then stores it in the $Datastore variable.

The ninth command gets the specified resource pool, and then stores it in the $ResourcePool variable.

The tenth command creates a recovery option, and stores it in the $ROption variable.

The last command restores the recovery point in $RPoint using the recovery options in $ROption.

PS C:\>  $PGroup = Get-DPMProtectionGroup -DPMServerName "DPMServer02"
PS C:\> $PObject = Get-DPMDatasource -ProductionServer $PGroup
PS C:\> $RPoint = Get-DPMRecoveryPoint -Datasource $PObject
PS C:\> $PS = Get-DPMProductionServer 
PS C:\> $Inventory= Get-DPMVMwareInventory -ProductionServer $PS
PS C:\> $Folder = $Inventory.RootFolder.ChildFolder[0].ChildFolder[1] 
PS C:\> $Host = $Inventory.ComputeResources[0].Hosts[0]
PS C:\> $Datastore = $Host.datastores[0]
PS C:\> $ResourcePool= $Inventory.ComputeResources[0].RootResourcePool
PS C:\> $ROption = New-DPMRecoveryOption -VMwareVM -TargetServer "VCenterServer" -VMWareTargetFolder $Folder -VMwareTargetHost $Host -VMWareTargetDatastore $Datastore-VMwareTargetResourcePool $ResourcePool
PS C:\> Restore-DPMRecoverableItem -RecoverableItem $RPoint -RecoveryOption $ROption

Get-DPMProtectionGroup

Get-DPMDatasource

Get-DPMRecoveryPoint

Get-DPMLibrary

Get-DPMProductionServer

Get-DPMVMwareInventory

Restore-DPMRecoverableItem