venerdì 13 dicembre 2013

VMware: vSphere Replication Part 6 - Perform Recovery

When everything goes berserk it is time to perform a recovery!!
vSphere Replication's main goal is to allow administrators to recover corrupted or lost VM disks. Recovery process is quite simple yet at the same time really ingenious. How does it works?

On a global level the process comprises the following steps:

1)Select VM to recover
2)Recover VM on replication site, power it on, verify it works as expected
3)Configure an inverse replication process to move back VM from destination to source site

Let's now delve more into these steps to see how recovery is performed.

As first it could be intresting to note the fact that if virtual machine is available at source site vSphere Replication allows you to synchronize disk data back from target site to source site. This could be useful in case of something goes wrong at source site VM but VM itself is still available and running.

For this article purpose I will consider a proper failure scenario in which VM at source site went corrupted.

As pointed out in previous articles my lab comprises two sites: SiteA and SiteB each managed by a different vCenter.

To perform VM recovery connect to vCenter at remote site (SiteB) and select Monitor -> vSphere Replication -> Manage -> Incoming Replications. Select the VM, right click on it and then click Recover button.

Recover procedure will pop-out and will guide you through the process.
First selection concerns recovery options, as said before I will go through a complete failure of source SiteA.

Select where to recover VM. In this case I created a dedicated folder in my datacenter where to place recovered VMs.

Select host that will host your VM

Then when ready click Finish. You also might want to select Power on the virtual machine after recovery. Don't worry about potential VM IP address conflicts, I will later explain why.

Once recovery has been performed a new VM will be created on your source site (SiteB) and on Summary tab of the VM you will be informed the VM was recovered.

If when enabling replication you selected to keep PIT copies of your VM all these point in times were associated to the VM as form of snapshots. To recover VM state at a certain PIT right click VM, select Snapshots Manager and all snapshots (PITs) will be listed there.

Once the VM has been recovered to the desired PIT and powered on if you open VM console you will notice that VM has no network attached. This is because recovering a VM and powering it on on remote site (SiteB) could introduce IP addresses conflicts with other VMs already there at the remote site.
To prevent such conflicts by default recovered VMs has no network connected.

To re-attach network adapter in recovered VM just right click it, select Edit Settings and check Connected box right to the network adapter.

VM is now fully functional at remote site (SiteB) but how about moving it back to local site (SiteA)? To move VM back to source site a reverse replication must be configured. By enabling vSphere Replication on recovered VM at target site back to source site will bring VM back at it's original place.

This can be performed as explained in vSphere Replication Part 5 - Enable Replication article reversing sites i.e. SiteB will be source site and SiteA will be destination site.

Other blog posts in vSphere Replication Series:

vSphere Replication Part 1 - Introduction
vSphere Replication Part 2 - Installation
vSphere Replication Part 3 - Roles & Permissions
vSphere Replication Part 4 - Configuration
vSphere Replication Part 5 - Enable Replication
vSphere Replication Part 6 - Perform Recovery
vSphere Replication Part 7 - Provision additional Replication Servers

Nessun commento:

Posta un commento