Looking for a simple script to Power on a shutdown Nutanix VM. Perhaps there is already a thread on this but I couldn't locate it if so.
Thanks!!
Solved
Script to power on VM
Best answer by andymlloyd
Use the Powershell Cmdlets (download from Prism/Central) and then fire up Powershell:
## Get the VM Unique Identifer for the VM you want to power on
$myvmname=Read-Host "Enter the name of the VM to power on"
$myvm= Get-NTNXVM | where {$_.vmname -eq $myvmname}
$myvmID = ($myvm.vmid.split(":"))[2]
## Power on the VM
Set-NTNXVMPowerOn -vmid $myvmID
Enjoy 🙂
## Get the VM Unique Identifer for the VM you want to power on
$myvmname=Read-Host "Enter the name of the VM to power on"
$myvm= Get-NTNXVM | where {$_.vmname -eq $myvmname}
$myvmID = ($myvm.vmid.split(":"))[2]
## Power on the VM
Set-NTNXVMPowerOn -vmid $myvmID
Enjoy 🙂
This topic has been closed for replies.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.

