Hi team, I have a huge Exchang2012 to backup and restore while the network traffic would be too heavy and too long time expected for recovery. So I am planning to use DPM2012's SAN based recovery to acheive the fast recovery.
I found there is a post regarding the
integration between DPM and EMC SAN storage, but it's
for DPM 2007 . And my test to run this script got
errors when I ran it on my DPM 2012 management shell.
I am wondering if anyone can provide a version for
DPM 2012,or any document that I can refer to for
manual configuration with DPM2012 GUI to acheive the
SAN based recovery.
link to the document
http://www.emc.com/collateral/hardware/white-
papers/h4260-clariion-stor-sol-ms-dpm-wp.pdf
==============begin of the script
======================
if(!$args[0])
{
if(!$DSName)
{
$DSName = read-host "DatasourceName:"
}
}
else
{
if(("-?","-help") -contains $args[0])
{
write-host Usage::
write-host CreateShadowCopy.ps1 DatasourceName
ProtectionGroupName
write-host Help::
write-host Creates a shadow copy for the given
Datasource
write-host
exit 0
}
else
{
write-host "Usage -? for Help"
exit 1
}
}
if(!$PGName)
{
$PGName = read-host "ProtectionGroupName:"
}
$dpmname = &"hostname"
connect-dpmserver $dpmname
$pg = get-protectiongroup -dpmservername $dpmname
if (!$pg)
{
write-error "Cannot get the protectionGroup"
disconnect-dpmserver $dpmname
exit 1
}
$mypg = $pg | where {$_.FriendlyName -eq $PGName}
if (!$mypg)
{
write-error "Cannot get the requested
protectionGroup"
disconnect-dpmserver $dpmname
exit 1
}
$ds = get-datasource -protectiongroup $mypg
if (!$ds)
{
write-error "Cannot get the datasources for the PG"
disconnect-dpmserver $dpmname
exit 1
}
$myds = $ds | where {$_.Name -eq $DSName}
if (!$myds)
{
write-error "Cannot get the required Datasource"
disconnect-dpmserver $dpmname
exit 1
}
$j = new-recoverypoint -datasource $myds -
DiskRecoveryPointOption
WithoutSynchronize -Disk
if (!$j)
{
write-error "Cannot get the required Datasource"
disconnect-dpmserver $dpmname
exit 1
}
$jobtype = $j.jobtype
while (! $j.hascompleted )
{
write-host "Waiting for $jobtype job to complete...";
start-sleep 5
}
if($j.Status -ne "Succeeded")
{
write-error "Job $jobtype failed..."
}
Write-host "$jobtype job completed..."
disconnect-dpmserver $dpmname
exit
===============end of the script=================
Here is the error , please advise,thanks! -KF
dpmserver.domain.com domain.com
New-DPMRecoveryPoint : Missing an argument for parameter 'DiskRecoveryPointOpti
on'. Specify a parameter of type 'Microsoft.Internal.EnterpriseStorage.Dls.Engi
neUICommon.EngineConstants.DbEnums+CreateDiskRecoveryPointOption' and try again
.
At C:\Program Files\Microsoft System Center 2012\DPM\DPM\bin\CreateShadowCopy.p
s1:62 char:66
+ $j = new-recoverypoint -datasource $myds -DiskRecoveryPointOption <<<<
+ CategoryInfo : InvalidArgument: (:) [New-DPMRecoveryPoint], Par
ameterBindingException
+ FullyQualifiedErrorId : MissingArgument,Microsoft.Internal.EnterpriseSto
rage.Dls.UI.Cmdlet.ProtectionCmdLets.CreateRecoveryPoint
The term 'WithoutSynchronize' is not recognized as the name of a cmdlet, functi
on, script file, or operable program. Check the spelling of the name, or if a p
ath was included, verify that the path is correct and try again.
At C:\Program Files\Microsoft System Center 2012\DPM\DPM\bin\CreateShadowCopy.p
s1:63 char:19
+ WithoutSynchronize <<<< -Disk
+ CategoryInfo : ObjectNotFound: (WithoutSynchronize:String) [],
CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
C:\Program Files\Microsoft System Center 2012\DPM\DPM\bin\CreateShadowCopy.ps1
: Cannot get the required Datasource
At line:1 char:23
+ .\CreateShadowCopy.ps1 <<<<
+ CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorExcep
tion
+ FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorExceptio
n,CreateShadowCopy.ps1
PS C:\Program Files\Microsoft System Center 2012\DPM\DPM\bin> .\CreateShadowCopy
.ps1
Thanks and best regards, -- KF