I’ve written about deploying ESXi hosts using AutoDeploy whilst covering the VCAP5-DCA objectives, but I didn’t go into stateful deployments or stateless caching.
By default, a host provisioned using AutoDeploy pulls down the ESXi image each time the host boots. If the AutoDeploy server, or TFTP server, isn’t available then the host will not be able to get it’s image and will not boot:
AutoDeploy Stateless Caching
Stateless caching addresses this by caching the ESXi image on the host’s local storage. If AutoDeploy is unavailable then the host will boot from its local cached image. There are a few things that need to be in place before stateless caching can be enabled:
- Hosts should be set to boot from network first, and local disk second
- Ensure that there is a disk with at least 1 GB available
- The host should be set up to get it’s settings from a Host Profile as part of the AutoDeploy rule set.
To configure a host to use stateless caching, the host profile that it will receive needs to be updated with the relevant settings. To do so, edit the host profile, and head to the ‘System Image Cache Profile Settings’ section, and change the drop-down menu to ‘Enable stateless caching on the host’:
Click OK to complete the change to the host profile. The next time a host that is configured to use this host profile reboots, it’s AutoDeploy image will be cached on it’s local disk, and will be able to use the cached image on subsequent restarts if any part of the AutoDeploy infrastructure happens to be unavailable.
AutoDeploy Stateful Installs
It is also possible to have AutoDeploy install ESXi. When the host first boots it will pull the image from the AutoDeploy server, then on all subsequent restarts the host will boot from the locally installed image, just as with a manually built host. With stateful installs, ensure that the host is set to boot from disk firstly, followed by network boot.
AutoDeploy stateful installs are configured in the same way as stateless caching. Edit the host profile, this time changing the option to ‘Enable stateful installs on the host’:
With this option set, when the host reboots and receives it’s AutoDeploy image, it will be installed to the hosts local disk.