Perform a Hyper-V Replica Initial Copy Via a Restore
An important step in implementing Hyper-V Replica is performing the initial copy. In this post, I will talk about how to perform the Hyper-V Replica initial copy by restoring virtual machines from backup in the secondary site. (There’s actually three ways to do perform an initial copy. In these previous posts, I showed you how to perform the Hyper-V Replica initial copy using external media or removable storage and how to perform a Hyper-V Replica initial copy over the network.)
Initial Copy Using a Restore: How It Works
One of the options for performing a Hyper-V Replica initial copy is to restore the virtual machines from backup in the secondary site. The hard bit of this operation is getting the backup content to the secondary site in the first place.
It is typically considered good practice for a company to store copies of their backups in an offsite location. Some will choose to store their backup tapes in a safe location at the secondary or disaster recovery site. Others might have a backup solution, such as System Center Data Protection Manager (DPM), which is able to automatically replicate disk-to-disk backup content from the primary site to the secondary site.
Passwords Haven’t Disappeared Yet
123456. Qwerty. Iloveyou. No, these are not exercises for people who are brand new to typing. Shockingly, they are among the most common passwords that end users choose in 2021. Research has found that the average business user must manually type out, or copy/paste, the credentials to 154 websites per month. We repeatedly got one question that surprised us: “Why would I ever trust a third party with control of my network?
Replicating backup to the secondary site.
Hyper-V administrators can use this backup data to seed the replication process. When you want to replicate a virtual machine using Hyper-V Replica, you restore that exact virtual machine from backup to the replica host in the secondary site, and then walk through the Enable Replication wizard in the primary site. The differences between the running virtual machines in the primary site and the offline restored virtual machines in the secondary site are fixed up, and replication commences. Note that the wizard will not complete if you have not already restore the exact virtual machine in the secondary site.
Hyper-V Replica Initial Copy Using a Restore: Pros and Cons
There are two significant benefits of this approach to performing an initial copy.
- Minimum bandwidth required: The initial copy is being done out of band by restoring the required virtual machines from backup in the secondary site. Only the differences between the running VM and the state it was in during the last backup are sent over the wire to fix up the replica VM before replication can continue.
- Reuse existing investment: No additional equipment might be required, especially if backup media are being replicated/stored to the secondary site. The backup system is being used to seed the replica VMs.
There are some cons to this practice as well.
- Not self-service-friendly: In theory, a runbook (maybe System Center Orchestrator) could be created to automate the VM restore and replication enablement. But for most, this will be a very manual process (unlike the network copy). This would make this operation unsuitable for a service-oriented environment (a cloud) where self service is required. Self service typically requires an initial copy via the replication network link.
- Backup not available: If you do not store backups in the DR site, either because you use another storage location or you do not replicate backups, then this approach will be difficult or impossible to implement. You might want to consider using the removable media method instead of this one.
Implementing the Initial Copy
The first step in the process is to identify each virtual machine that you wish to use this approach for in order to perform the Hyper-V Replica initial copy. Then you need to restore each virtual machine to the required replica hosts in the secondary site. I need to be clear here: If you want to replicate a VM then you need to restore that exact VM, not another VM that’s almost identical.
Launch the Enable Replication wizard, choosing the option to Use An Existing Virtual Machine On The Replica Server As The Initial Copy.
Selecting the option to use a restored copy of the virtual machine.
The wizard will fail to configure replication if you have not already restored that exact virtual machine on the selected replica host/cluster.
The wizard will complete, the seeded replica VM will be fixed up and replication will commence.