Module 9
Implementing failover clustering
with Windows Server 2016 Hyper-V
Module Overview
Overview of the integration of Hyper-V
Server 2016 with failover clustering
Implementing Hyper-V VMs on failover clusters
• Key features for VMs in a clustered environment
Lesson 1: Overview of the integration of Hyper-V
Server 2016 with failover clustering
Options for making application and services highly
available
How does a failover cluster work with Hyper-V
nodes?
Failover clustering with Windows Server 2016
Hyper-V features
• Best practices for implementing high availability in
a virtual environment
Options for making application and services
highly available
High availability options Description
Host clustering • VMs are highly available
• Does not require VM operating
system or application to be cluster-
aware
Guest clustering • VM are failover cluster nodes
• VM applications must be cluster-
aware
• Requires iSCSI or virtual Fibre
Channel interface for shared storage
connections
NLB • VM are NLB cluster nodes
• Use for web-based applications
How does a failover cluster work with Hyper-V nodes?
Shared bus or
iSCSI connection
Cluster
storage
A dedicated network
connects the
Node 1 Node 2
failover cluster nodes
Failover clustering with Windows Server 2016
Hyper-V features
Failover clustering with Windows Server 2016
Hyper-V features:
• Maximum nodes and VM support 64 N / 8.000 VMs
• File share storage:
• W2012 Introduced Storing VMs on (SMB 3.0) file shares in a
SOFS file server cluster
• .vhdx (W2012/R2 /2016/2019) Support Up 64TB
• .vhds (Windows Server 2016 only) GUEST Cluster Storage SOFS
• Shared virtual disk (W2012r2 Only in SCSI Vhdx)
• For GUEST Cluster Storage in SOFS for better avaliability
• Rolling Hyper-V cluster upgrades
• VM configuration version
Best practices for implementing high availability
in a virtual environment
Best practices for implementing high
availability in a virtual environment:
• Plan for failover scenarios
• Hardware capacity that is required when hosts fail
• Plan the network design for failover clustering
• Fast Network Connections / NIC Teaming /SET
• Redundant switches
• Separate network segment Client/HeartBeat/Storage
• Plan the shared storage for failover clustering
• Shared storage must be highly available RAID/SOFS
Best practices for implementing high availability
in a virtual environment
Best practices for implementing high
availability in a virtual environment:
• Use the default failover cluster quorum mode
• Dynamic Quorum / Dynamic Witness (not Modify)
• Deploy standardized Hyper-V hosts
• Server Core Best Option
• Develop standard management practices
• Increase the risk that a single mistake
• Drain Node / Pause Node
• Be carefully for host Shutdown ( All VM FailOver to
another Node)
Lesson 2: Implementing Hyper-V VMs on
failover clusters
Components of Hyper-V clusters
Prerequisites for implementing Hyper-V failover
clusters
Implementing Hyper-V VMs on a failover cluster
Configuring CSVs
Configuring a shared virtual hard disk
Implementing Scale-Out File Servers for VMs
Considerations for implementing Hyper-V clusters
Maintaining and monitoring VMs in clusters
• Demonstration: Implementing failover clustering
Components of Hyper-V clusters
Hyper-V cluster components include:
• Cluster nodes
• Least two physical nodes
• Cluster networks Separately
• Cluster network (Private) / Client / Storage/ Live Migration
• Virtual networks
• Important to create the same virtual networks on all HyperV Nodes
• Storage for VMs
• Recommend that you configure storage as a CSV is a storage
architecture that is optimized for Hyper-V Virtual Machines
• VMs
• In Failover Cluster Manager make VMs highly available
• VM storage location must be on shared storage that is accessible for
all nodes
Prerequisites for implementing Hyper-V
failover clusters
• Hardware requirements for cluster nodes and storage include:
• Server hardware
• Network adapters
• Storage adapters
• Storage
• Software recommendations for cluster nodes include:
• Running Windows Server 2016 Standard, Datacenter, or Hyper-V
Server 2016 editions
• Require the same software updates and service packs
• Must be either a full installation or a Server Core installation
• Network infrastructure requirements include:
• Network settings and IP addresses
• Private networks
• DNS
• Domain role
• Account for administering the cluster
Implementing Hyper-V VMs on a failover cluster
To implement a Hyper-V VM on a failover cluster:
1. Install and configure Windows Server 2016
2. Configure shared storage
3. Install the Hyper-V and Failover Clustering
features
4. Validate the cluster configuration
5. Create the cluster
6. Create a VM on one of the cluster nodes
7. Make the VM highly available (for an existing VM)
8. Test the VM failover
Configuring CSVs
• CSV benefits:
• Allow multiple nodes to have read/write access simultaneously to
the same disk
• Fewer LUNs required
• Better use of disk space (store multiple VMs on a single LUN)
• Virtual machine files are in a single logical location
• No special hardware required
• Increased resiliency
• To implement CSV:
1. Create and format volumes on shared storage
2. Add the disks to failover cluster storage
3. Add the storage to the CSV
Configuring CSVs
Configuring a shared virtual hard disk for
building guest clusters
• Why: Do not have to provide Fiber Channel or iSCSI connection to
the VMs
• Failover cluster runs inside VMs
• Shared virtual disk used as a shared storage:
• VMs do not need access to iSCSI or failover clustering SAN
• Presented as a virtual serial-attached SCSI disk
• Can be used only for data
• Requirements for shared virtual hard disk:
• Must be in .vhdx or .vhds format
• Connected by using virtual SCSI adapter
• Stored on a Scale-Out File Server or CSV
• Windows Server 2012 or later is the supported operating
system in VM
Configuring a shared virtual hard disk
Implementing Scale-Out File Servers for VMs
• In Windows Server 2016, you can store VM files
on a SMB 3.0 file share
• File servers need to run Windows Server 2012
or later
• A file server cluster needs to be configured as a
Scale-Out File Server for application data
• Use Hyper-V Manager to create or move VM files
to a SMB file share
• CSV Cache W2012,Can allocate 20% of the total
RAM for CSV write-through cache, and 80
percent with W2012 R2 and W2016
Implementing Scale-Out File Servers for VMs
Set CSV Cache in SOFS to 52 GB (80%) Cache in 64Gb RAM Nodes
(Get-Cluster).BlockCacheSize = 52428
Considerations for implementing Hyper-V clusters
• Identify the following recommended failover clustering
requirements:
• Applications that require high availability
• Option of making all VMs highly available?
• Priorities for which applications you will make HA
• Application components that must be highly available
• Servers, Storage, Networks, WAN Links, ISP for Internet Access
• Application characteristics
• Is Virtualization Supported foe selected Application?
• Application Can Run in VMs HA?
• Required only Host Clustering?
• Total capacity requirements
• Identify all applications that you must make highly available by using host
clustering
• Calculate Server (RAM and CPUs), Storage and Networks requirements
• Used Similar Server hardware and same Processor manufacture for better
experience in Live and Quick Migration Process
Considerations for implementing Hyper-V clusters
• Windows Server 2016 Hyper-V Live Migration considerations:
• Verify basic requirements
• Require that all hosts must be part of a Windows failover cluster
• Processors must be from the same manufacturer
• all hosts in the cluster must have access to shared storage
• Can be use Live Migration Cluster-Less Without WFC
• Configure a dedicated network adapter or virtual network adapter
• this network to transfer the VM memory during a failover
• Use similar host hardware
• VMs on a host with different processor versions configure processor
compatibility settings
• failover experience and performance is more consistent if all servers
have very similar hardware
• Verify network configuration
• Network configurations need to be the same for all nodes in the
failover cluster
Processor Compatibility Configuration Hyper-V
clusters and Virtual Switch Name
Same Virtual Switch Name
For All Nodes in WFC
Maintaining and monitoring VMs in clusters
In Windows Server 2016 failover clustering, you
can implement the following technologies for VM
maintenance and monitoring:
• Service and VM health monitoring
• Network health detection (Windows Server
2012 R2 and later only)
• Virtual machine drain on shutdown (Windows
Server 2012 R2 and later only)
• (Get-Cluster).DrainOnShutdown=1
Service and VM health monitoring
Service and VM health monitoring
The event ID 1250 is logged to the cluster, telling that the VM is in a critical
state. This is detected during some health check interval in the cluster, and the
actions can take place
NetFirewallRule -DisplayGroup "Virtual Machine Monitoring" -Enabled $True
Network health detection
Lesson 3: Key features for VMs in a clustered
environment
Overview of Network Health Protection
Overview of actions taken on VMs when a host
shuts down
Overview of drain on shutdown
• Demonstration: Configure drain on shutdown
Overview of Network Health Protection
• Introduced in Windows Server 2012 R2 and
available in Windows Server 2016
• Recommend NIC teaming as the first level of redundancy
• Network becomes disconnected. VM Migrate to other Node
• Resource checks every 60 seconds
• Cluster resource checks availability of VM
resources
• Network Health Protection controlled individually
on each virtual network adapter
Overview of actions taken on VMs when a host
shuts down
Automatic Stop Action options:
• Save the virtual machine state
• Turn off the virtual machine
• Shutdown the guest operating system
Overview of drain on shutdown
• A failover cluster node placed in a paused state
uses live migration on VMs, removing downtime
• At shutdown a failover cluster node prior to
Windows Server 2012 R2 uses quick migration,
creating some downtime
• At shutdown a failover cluster node after
Windows Server 2012 R2 uses live migration,
removing downtime
Overview of drain on shutdown
Recommend draining all roles before shutting down a failover cluster node.
Drain on shutdown provides added protection against user error and circumstances if an
application or the operating system initiates a shutdown outside of the user’s control
Lab: Implementing failover clustering with
Windows Server 2016 Hyper-V
Exercise 1: Configuring virtual environment
Exercise 2: Configuring a failover cluster for Hyper-
V
• Exercise 3: Configuring a highly available VM
Logon Information
Virtual machines: 20740C-LON-DC1-C
Host machines: 20740C-LON-HOST2
20740C-LON-NVHOST3
20740C-LON-NVHOST4
User name: Adatum\Administrator
Password: Pa55w.rd
Estimated Time: 75 minutes
Lab Scenario
The initial deployment of VMs on Hyper-V has been successful for
Adatum Corporation. As a next step in VM deployment, Adatum
is considering ways to ensure that the services and applications
deployed on the VMs are highly available. As part of the
implementation of high availability for most network services
and applications, Adatum is also considering options for making
the VMs that run on Hyper-V highly available.
As one of the senior network administrators at Adatum, you are
responsible for integrating Hyper-V with failover clustering to ensure
that the VMs deployed on Hyper-V are highly available. You are
responsible for planning the VM and storage configuration, and for
implementing the VMs as highly available services on the failover
cluster. You have limited hardware; so, to facilitate testing before
implementation in your production environment, you will enable
nested virtualization to test clustering two Hyper-V Hosts.
Lab Review
What is an example of when you might not want
Protected Network selected for a Virtual Network
Adapter?
• What is the difference between live migration and
storage migration?
Module Review and Takeaways
Review Question
Tools
Best Practices
• Common Issues and Troubleshooting Tips