How to Deploy High Availability Hyper-V Cluster

When there is a planned or unplanned failure to your VM, what would you do to keep your VMs working continuously? In this article, I will introduce the detailed steps to set up Hyper-V failover cluster to protect VM comprehensively.

Crystal

By Crystal / Updated on March 8, 2023

Share this: instagram reddit

What is Hyper-V clustering

Hyper-V clustering is a connected unit of independent computers, and it’s a feature of Windows Server designed to protect virtual machines in the event of a failure. When a physical server in the cluster fails, another server will take over the services of the failed one, so this transferring process is called failover.

The role of Hyper-V clustering is to actively monitor the hosts within the cluster to see if they are working properly. The Hyper-V cluster includes a maximum of 64 nodes, and each cluster can have up to 8.000 virtual machines. With Hyper-V failover cluster, the perceived downtime will be very short, thus greatly increasing the availability of Hyper-V.

what is hyper-v clustering

Hyper-V clustering vs Hyper-V replica

Hyper-V clustering and Hyper-V replica are completely different solutions implemented to solve different problems.

Failover clusters are used for business continuity and Hyper-V replications are commonly used for disaster recovery. So, they are supporters for each other instead of adversaries.

Hyper-V cluster enables Hyper-V virtual machines to failover automatically in case of failures. However, Hyper-V replica can only support to enable failover manually for VMs. Besides, Hyper-V clustering does not lose data while transferring failover, but it is possible for replica to lose part of data.

However, not everyone should use Hyper-V clustering, you’d better choose a solution based on your needs. If you do not want to investigate additional costs for extra hardware and shared storage, Hyper-V replica is still a good choice for you. Meanwhile, learning how to set up Hyper-V replica is much easier than deploying a complex cluster system.

Benefits of Hyper-V failover cluster

Hyper-V clustering copes with planned and unplanned failovers effectively, which contributes to reducing shutdown time of servers and improve business continuity.

Planned failover: For example, VM data migration or maintenance, software upgrade, etc. Using planned failover in Hyper-V benefits to reducing downtime and increase availability.

Unplanned failover: In the case of unplanned events such as unexpected power outage, a natural disaster or virus attack, unplanned failover automatically take over the services on this server to reduce the downtime caused by hardware or software failure and the impact on business continuity.

failover clustering

Requirements for Hyper-V failover cluster

Before enabling failover clustering, you must verify that your software and hardware settings are compatible with Hyper-V clustering technology.

Shared Storage: If you plan to use a failover cluster in Hyper-V, you need to configure shared storage for the failover cluster first. Direct Attached Storage, iSCSI Storage, Storage Area Networking (SAN) and SMB 3.0 protocol (for Windows Server 2012 and later) are available to Shared storage.

Among them, you can use iSCSI introduced in Windows Server 2012 R2 to set up an "iSCSI target server". It saves the budget and fits who want to validate the cluster's functionality in a test environment.

CPU: It is recommended to use CPUs with native virtualization supports, and it’s better to use CPUs with same or similar components instead of different CPUs such as from Inter to AMD, since migration on different CPUs may lead to cluster failure.

Hyper-V Cluster Networking: Cluster nodes should be connected by some network in events of a single point of failure, so you need to configure identical communication setting on the same network adapters.

OS settings: Windows servers should be in the same domain, and have installed Hyper-V and failover cluster roles.

requirement of setting up cluster

How to set up failover cluster in Hyper-V step by step

After checking these requirements, you can go to create the Hyper-V failover Cluster. Please refer to the following steps to know how to set up Hyper-V failover cluster in Windows Server 2016.

Please run a validation test first of the cluster configuration in the Failover Cluster Manager.

1. Open Server Manager, and click Tools to select Failover Cluster Manager.

2. Click Validate Configuration and do the following:

validate configuration

3. In the opened wizard, click Browse to specify the Servers you want in the clustering.

specify servers for hyper-v failover cluster

4. At the end of validation, you can check whether there are any errors, and if you click View Report, it would generate a huge report describing every single problem. Then click Finish.

view report of setting

After finish the validation configuration, please go to create a new Hyper-V failover cluster now.

1. In the Failover Cluster Manager, navigate to Create Cluster.

create hyper-v failover cluster

2. In Select Server part, enter a name for the server or click Browse >> Advanced >> Find Now, then enter network credentials and click OK.

select servers for cluster

 

3. In the Access Point for Administering the Cluster section, type a name for the new cluster and provide an available IP address, then click Next.

4. Confirm the information is correct, and select Add all eligible storage to the cluster, then click Next.

5. Then it starts configuring the new cluster, and the process may take a while.

6. Click Finish to complete configuration.

a new hyper-v cluster

Here, you have set up a failover cluster in Hyper-V.

The Failover Cluster Manager contains 5 important components: roles, nodes, storage, network, and cluster events. In daily operations and maintenance, you are often exposed to the creation, deletion, and modification of various roles and functions. So, use failover clusters efficiently in Hyper-V will be very helpful to your work.

To improve the availability of failover clusters, the following part will introduce how to add a disk to store virtual machine data and how to create a highly available virtual machine.

How to add disks in Hyper-V failover cluster

Navigate to the Failover Cluster Manager, you can notice that failover cluster requires disk for storage.

Click Storage >> Disks >> Add Disk, check the available iSCSI disks and specify disks you need, then click OK.

add disks for hyper-v cluster

The disks are added into the cluster and they are all online. You could right click on a disk and choose Add to Cluster Shared Volumes.

How to create a highly available virtual machine

1. Click Roles >> Virtual Machines >> New Virtual Machines >> Next.

2. Specify Name and Location: enter a name for the VM, then select Store the virtual machine in a different location, and click Browse to choose the shared storage.

Note: Virtual machines must be moved to the cluster shared volume, otherwise the task of creating a highly available VM may fail.

3. Specify Generation, you can choose Generation 1 to maintain compatibility better, then configure the suitable amount of memory and select Use Dynamic Memory for this virtual machine.

4. Click Create a virtual hard disk and enter a name and location, then specify the size of hard disk.

5. Click Install an Operating System Later >> Finish.

Is backup necessary in Hyper-V clustering

Setting up Hyper-V clustering aims to protect data security. When you perform failover cluster, you may notice that it also has drawbacks. So, for enterprise that requires a high level of security, is there an efficient way to overcome these shortcomings?

Backup is the best solution. As you know, backup is a traditional and secure way to protect virtual machines in Hyper-V.

Here, I will use a professional and free Hyper-V backup software - AOMEI Cyber Backup. It offers centralized management of multiple devices, and saves additional cost on storage.

  • Schedule backup tasks: It helps to back up virtual machine data automatically, and delete old backup files regularly.
  • Easy-to-use: backup and restore multiple virtual machines via central console without complicated configuration and reinstallation.
  • Economical cost: It doesn’t require additional cost on hardware and shared storage than deploying failover cluster.
  • High stability: It has been rigorously tested and has high stability. And backup process is more stable.

Please hit the button below to download and use AOMEI Cyber Backup for free:

Download FreewareVMware ESXi & Hyper-V
Secure Download

*You can choose to install this VM backup software on either Windows or Linux system.

How to perform a secure & free backup in Hyper-V

In order to protect data and avoid financial damage, backup is necessary. This part introduces the detailed steps to perform an efficient backup using AOMEI Cyber Backup as an example.

1. Access to AOMEI Cyber Backup, then go to add Hyper-V device.

2. Click Task >> Backup Task >> Create New Task to start scheduling task.

create Hyper-V backup

● Select the host and virtual machines you want to back up, then click OK. It is allowed to select multiple VMs at the same time, which simplify the backup operations.

select VM

● Specify a local path or network path as backup location

Schedule VM backup method (full / incremental backup) and type (hourly / daily / weekly / monthly). It will run the task automatically and regularly.

schedule backup

● Click Start Backup.

3. Restore: You can easily restore a VM from backup version when an error occurs in your original VM.

restore Hyper-V VM

✍ While the Free Edition covers most of the VM backup needs, you can also upgrade to enjoy:
✦ Backup Cleanup: Specify retention policy to delete unwanted VM backups automatically, thus saving storage space and cost.
✦ Restore to new location: Easily make a clone of a virtual machine in the same or another datastore/host, without reinstalling or configuring a new VM.

With perfect backup tasks, it helps to protect multiple Hyper-V VMs automatically and securely, and it’s easy for you to manage virtual machines centrally.

Summary

Hyper-V clustering is a complex and efficient technology to protect virtual machines’ safety with highly availability. In this article, I have introduced what is Hyper-V clustering and how to set up Hyper-V failover clustering in details.

If you are in a VMware environment, you can create vSphere High Availability cluster to perform VM failover.

Crystal
Crystal · Editor
Crystal is an editor from AOMEI Technology. She mainly writes articles about virtual machine. She is a positive young lady likes to share articles with peolpe. Off work she loves travelling and cooking which is wonderful for life.