VMware Cloud Community
Schorschi
Expert
Expert

Auto-Deploy Stateless and Re-Parent or Re-Association of VMs to the same ESXi Stateless Host?

We have been using our own variant of ESXi stateless for about 6 years now since early in 2008, in part because Host Profiles was slow to mature, when we needed stateless, disk-less ESXi hosts, and in part because our custom solution allowed us to bind policies or rules to a vCluster for storage, networking and re-parent VMs to ESXi hosts even if stateless, before VMware even thought of Auto-Deploy.  Well, the world has changed, and we again looking at Auto-Deploy and Host Profiles as native elements of vSphere with the expectation that we might finally retire our custom solution.  The handing of storage, networking, etc. under Host Profiles and Auto-Deploy used to invoke a specific Host Profile is pretty straight forward and similar to our custom solution.

But the one key gap is what we call re-parenting of VMs to a stateless ESXi host, if we deem that of benefit.  This is nice if you happen to have some VMs that are pinned or have some pretty strict affinity rules, which we do in our environment, a minority, but still of note.  This took a bit of interesting code driving the VMware API, but we did it, and it works well, if a bit slow at times.  The key issue with our custom solution is that it is dependent on a classic race condition with vCenter, since we are querying vCenter for something that once existed not what does in fact exist now.  This works because vCenter remembers which VMs where owned by a given stateless ESXi host long enough for us to leverage that information.  A voiding the debatable validity of this technique, the fact is, it works, and is an elegant if not official methodology.

What is interesting, is we don't see any similar feature with Auto-Deploy stateless?  Which we expected.  Auto-Deploy stateful is not an issue of course, but Auto-Deploy stateless, at least to us seems to be a significant gap.  Every time a ESXi (Auto-Deploy) stateless instance comes up, how does one ensure the same VMs are on the same exact ESXi host if so needed or desired?  Of course, this begs the question as to maintenance mode, and no VMs would be expected to be associated with a given host under maintenance mode which ESXi stateless is reloaded, but under our custom solution, if an ESXi fails or reboots unexpectedly, we don't have to rely on HA/DRS at all, and that is key, our variant of ESXi stateless is much faster by avoiding HA/DRS unless we deem it appropriate to use same.  The only way we can see this working well with Auto-Deploy is to use HA/DRS without exception?  To establish some rather complex DRS rules to VMs return to the rebuild ESXi host, under Auto-Deploy?  It appears that is the only VMware native solution to Auto-Deploy based stateless VM re-parent or re-association feature gap?

Has anyone tackled this issue, using Auto-Deploy?

0 Kudos
0 Replies