Azure / Azure/aksArc

Set AntiAffinityClassNames on AKS-HCI VMs

Open
#281 2 comments 1 reaction 0 assignees View on GitHub
Enhancement
Dominant language
PowerShell
Stars
118
Forks
63
PR merge metrics
No merged PRs in 30d

Description

**Title**:
Set AntiAffinityClassNames on AKS-HCI VMs

**Description**:
This is a feature request to make use of Hyper-V's built-in anti-affinity rules to ensure AKS VMs do not run on the same host. I have a 4-node AKS-HCI cluster, and I noticed on several occasions that multiple VMs within the same node pool ended up on the same physical host. This is not ideal for HA. If all the worker nodes in a pool are running on the same physical host, and that physical host goes down, then all workloads in that pool also go down. Pods with multiple replicas should run on separate physical hosts where possible.

Each control plane and worker node pool should have a unique anti-affinity class name assigned so that the Failover Cluster will ensure the VMs run on different physical hosts, but VMs in different node pools can still run on the same host. This could be computed based on the AKS cluster name + worker node pool name (or "controlplane" for the control plane VMs)

Description of Anti-affinity feature: https://learn.microsoft.com/en-us/windows-server/failover-clustering/cluster-affinity

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.