I've 13 Hyper-V nodes in a Microsoft Failover Cluster. About 50% of our guests are Linux and work best with static MAC addresses. Our Windows guests work either way, but to keep things simpler we've been setting them to static mac addresses as well.
Our procedure has been: provision VM, before installing OS, turn VM on, turn it off, change the network adapter to Static, keeping the autogenerated mac address.
The issue is:
- Create guest on Node1. It gets a MAC inside Node1's MAC range.
- Move guest to Node2. No problem.
- Create new guest on Node1. It gets a MAC inside Node1's range. I thought for sure that Failover Cluster was would be smart enough to check that there was no conflict with ANY guest but it just picks a random one from THAT NODE's range that isn't used by any guests on THAT NODE, not elsewhere in the cluster.
- I was depressed to find that this has actually created MAC conflicts where it stumbles on the same address it's already assigned to a guest that has migrated to a different node.
The short term solution's easy, we just run a PowerShell command to xref the MAC addresses over the entire cluster, but what's the long-term solution here? Should we check each autogenerated MAC address across all of the VM's in our pool? If we give each Hyper-V node the same pool, will it check across the entire cluster, or will we have even more collisions? Would SCVMM help us here, or make things worse?