Eqaully Live Migrate VMs in Failover Cluster Windows 2016

Prakash Thakor 1 Reputation point
2020-08-27T13:07:59.397+00:00

Hello,

We have Windows 2016 Hyper V Cluster,

After rebooting one of the Node forcefully due to some Hardware issue.

Is there any way or Power shell command so that we can equally Live Migrate VMs to hyper-V Nodes instead of doing manually .

Thanks,
Prakash Thakor

Hyper-V
Hyper-V
A Windows technology providing a hypervisor-based virtualization solution enabling customers to consolidate workloads onto a single server.
2,560 questions
Windows Server Clustering
Windows Server Clustering
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.Clustering: The grouping of multiple servers in a way that allows them to appear to be a single unit to client computers on a network. Clustering is a means of increasing network capacity, providing live backup in case one of the servers fails, and improving data security.
962 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. TimCerling(ret) 1,156 Reputation points
    2020-08-27T13:34:25.363+00:00

    Yes, PowerShell can be used to 'balance' the load of VMs across cluster nodes. The first step is for you to define what you mean by 'equally'. If it is simply a matter of having the same number of VMs on each node, you can write a script to counts the VMs on any host and then move the number you want to another host. Whatever you deem appropriate for your definition of equality can be placed into the PowerShell script to determine which VMs to migrate.


  2. Ian Xue (Shanghai Wicresoft Co., Ltd.) 30,376 Reputation points Microsoft Vendor
    2020-08-28T07:51:03.443+00:00

    Hi,
    Load balancing is enabled by default and you could coufigure it with the cluster property AutoBalancerLevel. In powershell you could run

    (Get-Cluster).AutoBalancerLevel = <value>  
    
    value    behavior  
    1        Move when host is more than 80% loaded  
    2        Move when host is more than 70% loaded  
    3        Average nodes and move when host is more than 5% above average  
    

    For more details you could refer to this link
    https://learn.microsoft.com/en-us/windows-server/failover-clustering/vm-load-balancing-deep-dive

    Best Regards,
    Ian

    ----------

    Please remember to "Accept Answer" and upvote if the reply is helpful.

    0 comments No comments