Creating a Recovery Plan is a very good thing but how do make it work the way we want it to? Well, every Recovery Plan has to be configured for the fact that, virtual machines depend on other machines in many ways, for example, the DB server has to powered on first for the app server and web server to connect to it and in some cases, we want to run some start-up scripts so that the machine can become available to users. All such things have to be fed to the recovery plan. So let’s see how that is done.
Recovery Plan run a series of steps that are performed in a specific order, the order cannot be changed, however, we can insert our own steps like displaying messages and run commands. Each Recovery Plan Steps are run different and not all steps are same i.e, steps for recovery differs from steps for reprotect. It is very much important to understand how recovery steps run, their order and context in which they run to be able to customize a recovery plan.
When a recovery plan is run, the virtual machines on the protected site are powered off according to the priority set with least priority machines turned off first. SRM avoids this step when a recovery plan is tested. Site Recovery Manager powers on the VMs at the recovery site also according to the priority set and is done is groups. If there exists any dependencies within the groups, SRM waits untill they are resolved or failed and any dependencies out of a priority group are ignored. SRM always tries to power on as many VMs as possible.
SRM can run custom steps on either the SRM server or the VMs that are part of the recovery plan. If a priority is changed on the virtual machine, the priority applies to the virtual machine in all the recovery plans. SRM uses VMware Tools heartbeat to discover when a virtual machine is powered on or off and thus it makes sure that the next priority group virtual machines are not powered on before higher priority VMs are completely up.
The different recovery steps that are run for Test, Recovery, Cleanup and Reprotect can be viewed as below .
Once the Recovery Plan is created, it can be customized as per our needs.
Priority for the VM power on can be set from the actions menu as below.
To completely configure the VM settings for the recovery, use the settings icon after selecting the VM. As you can see the priority can be set from this screen as well. Startup action can be set, pre power on steps and post power on steps can be configured here.
To customize the IP settings on a VM at the recovery site, use the next tab IP Customization. If there is no IP customization, SRM uses the same IP settings during the test and recovery as that of the protected site.
I have configured some of the settings in my lab and below is how the recovery plan is finally.
Hope this was informative. Thanks!