Start

This method starts or reconfigures the given recovery plan, or tests and cleans it up, depending on the mode specified. This operation requires one of these privileges depending on recovery mode, VcDr.RecoveryProfile.com.vmware.vcDr.Failover for a real recovery and VcDr.RecoveryProfile.com.vmware.vcDr.Run for a test recovery. You must use the UI, not the API, to initiate forced failover. It requires complicated set‐up and validation steps.

Note: This method is deprecated. You should not rely on it in production code, as it is not guaranteed to provide valid information in future releases. Instead, you should use StartEx.

Synopsis

void start(RecoveryPlan.RecoveryMode mode, @version5 @optional RecoveryOptions options)
  • mode – one of the following recovery modes:
    • test – run a test failover to the peer (recovery) site, without halting the local (protected) site.
    • cleanupTest – after testing a recovery plan, cleans up all effects of the test operation.
    • failover – move to the peer (recovery) site. When all groups are moved the recovery plan is complete.
    • reprotect – the peer site becomes the protected site, and the local site becomes the recovery site.
    • revert - revert a recovery, abandoning all the VMs on the peer site and powering on the original VMs on the local site. This operation is not allowed unless all the replication groups are in the shadowing, recovered, or partially recovered state. If the sites are not connected, the peer VMs may be left running. In order to correct this situation, you might have to re-run revert after the sites are connected.
    • migrate - Migrate the recovery plan to the peer site. Once completed successfully, the plan should be deleted or reprotected. For a successful migration to occur, all the groups in the plan must be in the shadowing or recovered states.
  • RecoveryOptions data object has the following properties:
    • syncData: It is a boolean parameter that indicates whether to replicate the recent changes to the recovery site. This option is valid only for the test operation. If not specified, the default value of true is used.
    • ignoreErrors: It is a boolean parameter that indicates whether or not to ignore errors during recovery operations such as cleanupTest and reprotect . If not specified, the default value of true is used.

Faults

  • IvalidArgument, if the recovery mode is not valid.
  • InvalidState, if the recovery plan is not in the ready state.
  • RuntimeFault

For information about the faults that Site Recovery Manager throws, see Faults in Site Recovery Manager API.

Example for Start

srmPortType.start(
        ManagedObjectReference _this,
        SrmRecoveryPlanRecoveryMode mode,
        SrmRecoveryOptions options);

	Where ManagedObjectReference _this = _recoveryPlan;
	where _recoveryPlan can be taken from:
SrmServiceInstanceContent content = _srmPortType.retrieveContent(_svcRef);
ManagedObjectReference _recoveryRef = content.getRecovery();
List<ManagedObjectReference> plans = srmPortType.listPlans(
        _recoveryRef);
ManagedObjectReference _recoveryPlan = plans.get(0);