Associatevms; Unassociatevms - VMware VC-SRM4-A - vCenter Site Recovery Manager Developer's Manual

Site recovery manager api
Table of Contents

Advertisement

Site Recovery Manager API Developer's Guide

AssociateVms

This method associates one or more virtual machines with a specified VR protection group. Before you can 
protect a virtual machine, it must first be associated with a protection group.
Example 3-41. Method to associate virtual machines with a protection group
void _service.AssociateVms(_svcPtGrp, VirtualMachine[] );
Parameters:
_svcPtGrp – managed object reference to an SrmProtectionGroup object
VirtualMachine[] – an array of managed object references to VirtualMachine object(s)

UnassociateVms

This method removes the association of one or more virtual machines with a specified VR protection group. 
Once a virtual machine is unassociated, it can no longer be protected.
Example 3-42. Method to unassociate virtual machines with protection group
void _service.UnssociateVms(_svcPtGrp, VirtualMachine[] );
Parameters:
_svcPtGrp – managed object reference to an SrmProtectionGroup object
VirtualMachine[] – an array of managed object references to VirtualMachine object(s)
32
VMware, Inc.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Vcenter site recovery manager 5.0

Table of Contents