Quantcast
Channel: Hyper-V forum
Viewing all articles
Browse latest Browse all 8743

shutting down a VM using a Powershell script based on VHD location

$
0
0

Hi Guys,

Im trying to shutdown a VM based on its VHD location. Basically i'm trying to change a script that installs Integration services while a VM is turned off. I need to shutdown the VM first but all im passing in is the path to the VHD. I know there is Stop-vm but you have to provide the name of the VM, which I dont have. Is there a way to output the VM name using the Get-VHD command?

I know this is probably a little basic so I appologise in advance.

Thanks


Viewing all articles
Browse latest Browse all 8743

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>