Handy list of commands when managing VMs on a server with Windows Core installed
- Get-VM
- Will list the state of all the VMs
- Stop-VM “VM-Name”
- Will turn the VM specified Off
- Start-VM “VM-Name”
- Will turn the VM specified On
- Get-VM “VM-Name” | Select-Object -Expandproperty HardDrives
- Shows what hard drives are attached
- Get-VM “VM-Name” | Select-Object *
- Shows a lot of information about the VM
Reference:
https://docs.microsoft.com/en-us/powershell/module/hyper-v/add-vmharddiskdrive?view=win10-ps
https://docs.microsoft.com/en-us/powershell/module/hyper-v/remove-vmharddiskdrive?view=win10-ps
https://www.nakivo.com/blog/essential-hyper-v-powershell-commands/
https://redmondmag.com/articles/2018/08/08/retrieving-detailed-info-about-hyper-v-vms.aspx