Hi,
What my understanding for the Failover operation (Planned and Unplanned) from VMware SRM is actually bringing up the VM to other site. As the same is handled at VMware SRM UI level individually with two different option.
--
Planned failover attempts to refresh and sync the last pending delta to Replicated site and performs operation.
Unplanned Failover is actually to recover VM at Target site from available replicated data.
--
As per SDK documentation, it details only one method to perform but there is no detail for separate option to perform Planned/unplanned Failover operation.
Method:
void start(RecoveryPlan.RecoveryMode mode, @version5 @optional RecoveryOptions options)
Please advise how to handle these individual actions from VMware SRM API.
Hi,
you can use the optional parameter RecoveryOptions.syncData = true to replicate the recent changes.
$RpRecoveryOption = New-Object VMware.VimAutomation.Srm.Views.SrmRecoveryOptions
$RpRecoveryOption.SyncData = $true
Excerpt from the documentation state (Online Documentation - Site Recovery Manager API Developer's Guide - VMware {code} 😞
void start( RecoveryPlan.RecoveryMode mode, @version5 @optional RecoveryOptions options)
options specifies the recovery options. The RecoveryOptions.syncData is a boolean parameter and indicates whether to replicate the recent changes to the recovery site.
Hope this helps,
Daniel G.
Hi Daniel,
Thanks for your response. I tried with SyncData boolean option, it worked.
After further testing with actual disaster scenario when Primary SRM was unavailable and attempted for the recovery with the same property flag
"RecoveryOption.SyncData=$true", it's realized that the disaster recovery (unplanned) was completed without synchronization (In fact VM synchronization failed because Primary site was unavailable and moved to next action). Though the property value should be false for RecoveryOption.SyncData during unplanned recovery but Planned recovery must fail due to synchronization failure.
Is there anyway with VMware SRM API - FAILOVER option when the property value is true for "RecoveryOption.SyncData" in case Primary site SRM is not available,
the planned failover JOB should fail ?
There is one what i could think i.e. checking primary SRM availability at first before Planned failover execution. However, it should have been good if anyway to control at Method as below...
void start(RecoveryPlan.RecoveryMode mode, @version5 @optional RecoveryOptions options)
Please advise.
Regards
Sameer Kumar
Hi Daniel,
Could you please advise how to control planned and unplanned failover ?Though RecoveryOption.SyncData has $true value. However, SRM API performs unplanned failover when production is not available. In fact, it should not skip VM Synchronization and must fail while performing Failover with Options (RecoveryOption.SyncData=$true)
Please let me know any inputs.
Regards
Sameer
Hi,
Could you please instruct how to handle certain SRM operation e.g.
- If the option SYNCDATA option $true fails to synchronize the VM, SRM Recovery Failover operation should fail and revert back VM to original state, should not perform unplanned failover
Please advise...