Blog
By Pete Zerger on 1/8/2010 5:01:18 AM • Rank (2120) • Views 2307
0

0

image There was recently a question in the Data Protection Manager forum (HERE) about the possibility of automating the restore of a single file share that is part of a protection group in Data Protection Manager 2007. Full-time OpsMgr 2007 MVP and Data Protection Manager 2007 guru David Allen posted a good sample script to illustrate how to do exactly that.This sample could be very easily parameterized to support ad-hoc and scheduled execution. Nice work David!

You can find a collection of several Data Protection Manager command shell scripts here on the on the System Center WIKI at http://www.systemcentercentral.com/WIKI/WIKIDetails/tabid/146/IndexId/24199/Default.aspx

Sample Script – Recover Individual File Share Resource

$DPMServerName = "ServerName"

$ProtectionGroup = "ProtectionGroupName"

$Datasource = "DatasourceName"

$ShareName = "ShareName"

$DestinationLocation = "RestoreLocation"

$DestinationServer = "ServerName"

$pg = Get-ProtectionGroup -DPMServerName $DPMServerName | where { $_.FriendlyName -eq $ProtectionGroup }

$ds = Get-Datasource $pg | where { $_.Name -eq $Datasource }

$rpl = Get-RecoveryPoint $ds | sort -Property RepresentedPointInTIme -Descending

$rp = $rpl[0]

$ri = Get-RecoverableItem -RecoveryPointForShares $rp | where { $_.UserFriendlyName -eq $ShareName }

$ro = New-RecoveryOption -TargetServer $DestinationServer -RecoveryLocation copytofolder `
-FileSystem -AlternateLocation $DestinationLocation -OverwriteType overwrite -RestoreSecurity -RecoveryType Restore         

Recover-RecoverableItem -RecoverableItem $ri -RecoveryOption $ro 

 

DPM Futures

Data Protection Manager 2010 is now available as well, and builds on the capabilities of 2007, addressing some key shortcomings of DPM 2007. You can download the DPM 2010 beta on the Microsoft Connect Website.

Comments - Comment RSS


Who Viewed
Who Reviewed
Categories
Related Pages
Shortened URL
http://tinyurl.com/yfraygk

Top Contributors
Featured Members
Pete Zerger
Points: 65622
Level: System Center Expert
Tommy Gunn
Points: 42748
Level: System Center Expert
Simon Skinner
Points: 40804
Level: System Center Expert
Stefan Koell
Points: 28999
Level: System Center Expert
Andreas Zuckerhut
Points: 27734
Level: System Center Expert