Move hosts between Hyper-V cluster

rstrappy 1 Reputation point
2022-11-23T08:56:31.79+00:00

Ciao,
right now, I have a Hyper-V 2019 failover cluster of 7 nodes with different CPU (3 host with Xeon GOLD 5120, and 4 hosts with Xeon Gold 6354).
I would like to split the actual cluster into two different cluster one with 3 hosts with 5120 and the other one with 4 host with 6354 leaving the VMs that actually runs on 5120 on hosts with 5120 and VMs that now runs on 6134 on hosts with 6134.
Is it possibile to move a host with its VM between different cluster, or what will be the best way to achieve that goal without any disruptions?
Thanks
Roberto

Windows for business Windows Client for IT Pros Storage high availability Virtualization and Hyper-V
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Limitless Technology 44,751 Reputation points
    2022-11-24T11:13:17.14+00:00

    Hi. Thank you for your question and reaching out.

    Yes, you can migrate a running virtual machine using the Hyper-V Manager.

    1. Launch the Hyper-V Manager. (Click Tools >> Hyper-V Manager in Server Manager.)
    2. Go to the navigation window and pick a server. (To add other servers, perform the following steps: right-click Hyper-V Manager, select Connect to Server from the context menu, type the server name, and click OK.)
    3. Right-click the virtual machine in the Virtual Machines window, and then select Move. The Move Wizard appears as a result.
    4. Select the move type, destination server, and options using the wizard pages.
    5. Review your selections on the Summary page, then click Finish.

    REFERENCE: https://learn.microsoft.com/en-us/windows-server/virtualization/hyper-v/manage/use-live-migration-without-failover-clustering-to-move-a-virtual-machine

    ------------------------------------------------------------------------------------------------------------------------------------

    If the reply was helpful, please don’t forget to upvote or accept as answer, thank you.

    0 comments No comments

  2. Eric Siron 1,586 Reputation points MVP
    2022-12-10T19:39:12.27+00:00

    Shared storage is going to be the biggest trick here. If you're hosting VMs from SMB then there won't be a problem. If they're on CSVs then you might have troubles because multiple clusters can't access the same CSV. Plan that part out first.

    To split the cluster in two:

    1. Use Failover Cluster Manager to pause a candidate node and drain its VMs to another node
    2. Evict the paused node from the cluster
    3. In PowerShell, run "Clear-ClusterNode -Force" directly on the recently evicted node
    4. Create a new cluster with it from the evicted node
    5. Repeat steps 1-3 for other nodes that you want in the cluster, adding them to the new one that you created in step 4

    On the original cluster, use the "Remove" function in Failover Cluster Manager on the virtual machine(s) to move to the new cluster. Then you can use Hyper-V Manager to migrate them from their original cluster to a node in the new. Since you have different CPUs, this can only happen online if you already enabled the option to "Migrate to a physical computer with a different processor version" on each VM to move. Otherwise, you will have to take a downtime window to shut the VM off (not saved) and migrate it. After you complete the migration, use Failover Cluster Manager to add the virtual machine back into high availability mode.

    Depending on your storage situation and host capacity/VM load, you may need to stagger migrations gradually as you evict and rejoin nodes. There's nothing wrong with that.

    How-tos:
    Shared Nothing Live Migration (migrate VMs outside a cluster); if you don't want to turn on processor compatibility mode and instead move the VMs offline, then this isn't necessary
    Processor compatibility mode
    Configure hosts for Shared Nothing Live Migration; note that this article indicates that it is for non-cluster joined machines. However, the parts in step 2 are also necessary on cluster-joined machines when you want to Live Migrate a virtual machine across, into, or out of clusters. The extra configuration is also not necessary if you will turn the VMs off to move them.

    The failover cluster documentation is unfortunately sparse, although you should have no trouble finding the actions that you need by right-clicking things (nodes for pausing, eviction, and adding virtual machines; VMs for removal; etc.). The PowerShell components:
    Remove-ClusterNode to end a node's cluster membership
    Clear-ClusterNode to clean up a node after eviction; you will need to do this anyway or evicted nodes will likely refuse to join a new cluster. There is no equivalent in Failover Cluster Manager.
    Remove-ClusterResource to remove virtual machines (and other things) from cluster coverage; if you're unfamiliar with PowerShell, this is a lot easier to do in Failover Cluster Manager by right-clicking the VM and clicking "Remove". For PowerShell, you can use Get-ClusterResource first to find the name of the VM(s), then use them in Remove-Cluster Resource. Ex: Remove-ClusterResource 'Virtual Machine webserver'. If you have some PowerShell experience, you can craft a Get-ClusterResource query that selects one or more virtual machines and pipes them to Remove-ClusterResource.
    Add-ClusterVirtualMachineRole to convert unprotected VMs on a node to high availability mode in the cluster
    Add-ClusterNode to add new nodes to a cluster
    Test-Cluster to validate final configurations and save new reports

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.