I have vSphere-Hypervisor with a few virtual machines running. Is there any way to achieve "clean" shutdown (of all VMs and ESXi) after power-button is pressed?
Welcome to the Community - Not that I am aware of - the best way to power down a host is through the vSphere client -
That is bad news. Is there really no acpi-event parser in esxi? I'm shocked. vSphere-client does not help, I do not have it always with me...
Can I at least shutdown VMs and ESXi using ssh? Or "magic tcp/udp packet"? Or any other way, except for vSphere-client...
You can do this via SSH (or via the console).
First, make sure SSH and/or console access to the host has been enabled
Then, this will tell you how to issue the shutdown command via the shell:
Note that VMs must have the client tools package installed for a clean shutdown.
Hi jdubin,
Welcome to the communites.
please find the below command hope will help you.
First of all you must list the ID of your VM’s
vim-cmd vmsvc/getallvms
then you can power off your VM’s:
vim-cmd vmsvc/power.off vmnumber
Then you can power on your vm’s after it’s done:
vim-cmd vmsvc/power.on vmnumber .
