I’ve been writing a lot of bash scripts recently to make my life a little easier. I have 15 VMs in my homelab running on ESXi. I had to shutdown my server recently to do some maintenance (i.e. adding more ram as it was running out and I didn’t particularly want to do SSD caching for the host) and had to manually shutdown all of my VMs. I started doing this and realised that there must be a better way of doing this and it turns out there is.