Hyper-V Program Manager
I was recently given an interesting challenge. I was asked to show how you could use PowerShell to import a virtual machine; where the virtual hard disks were stored in multiple different locations. Now, if the virtual hard disks were all in a single location, you could just use the “VHDSourcePath” parameter on Import-VM to let Hyper-V know where to look. But this does not work if the virtual hard disks are in multiple different locations.
To handle this situation – you need to use Compare-VM (as I discussed here).
The process I followed to do this is:
Now the virtual machine is imported and ready to go.