I haven’t been working with ESX for a bit, but while I was I was mostly interacting with it via the command line. Here is a list I had compiled while I was going through that exercise, and since I while be starting a job next week where I will no longer be interacting with much ESX I will just publish this one as-is. It is by no means complete and frankly it is not even that helpful. Notice that the commands which reference a specific virtual machine have a number, this is the VM ID for the VM you’d like to interact with.
This is specifically to interact with VMs on ESX 5. There is also esxcli which will allow you to make hypervisor level changes such as configuring a vSwitch, the esxcli is similar to a switch in how it behaves but it is beyond the scope of this article.
List All VMs on the Host
vim-cmd vmsvc/getallvmsGet Information for a Specific VM
vim-cmd vmsvc/get.guest 30Get Configuration for a Specific VM
vim-cmd vmsvc/get.config 30Get Summary for a Specific VM
vim-cmd vmsvc/get.summary 30Get Current Power State of a Specific VM
vim-cmd vmsvc/power.getstate 30Power On a Specific VM
vim-cmd vmsvc/power.on 30Power Off a Specific VM (Hard)
vim-cmd vmsvc/power.off 30Shutdown a Specific VM
vim-cmd vmsvc/power.shutdown 30Reboot a Specific VM
vim-cmd vmsvc/power.reset 30List a Specific VM’s Snapshots
vim-cmd vmsvc/get.snapshot 30Unregister a VM from a ESX Host
vim-cmd vmsvc/unregister 30Register a VM on a ESX Host
vim-cmd solo/registervm path/to/.vmx