ESXi Autostart VMs with CLI
Maintenance mode is great however, when you have a single ESXi host and you have perfected the perfect VM startup order and you have to place your host into maintenance mode how do you start your VMs in the same order without having to manually do it?
In this post, I will detail step-by-step how to start the VM auto-start sequence after you’ve exited maintenance mode.
- Enable SSH by right-clicking on the host and selecting Services > Enable Secure Shell (SSH)
- SSH into the ESXi host (I’m going to use PuTTY)
- Run the following command to autostart your VMs
Now your VMs will start booting up in the autostart order you created.
You can even tell your VMs to shutdown in the reverse order by just running the auto shutdown command
I tried to find official documentation from VMware about this process but I wasn’t able to find any.