Skip to content

Instantly share code, notes, and snippets.

@mcc85s
Last active November 10, 2022 15:10
Show Gist options
  • Save mcc85s/c7d498cad297804e86c18162379f57d1 to your computer and use it in GitHub Desktop.
Save mcc85s/c7d498cad297804e86c18162379f57d1 to your computer and use it in GitHub Desktop.
For converting a VirtualBox/VMware vmdk file to vhdx
# [VMDK] (VMWare/VirtualBox) -> [VHDX] (Hyper-V)
# https://gist.github.com/rahilwazir/69a750b70348459875cbf40935af02cb
# Microsoft Virtual Machine Converter (Link active as of 2021_0121)
# http://download.microsoft.com/download/9/1/E/91E9F42C-3F1F-4AD9-92B7-8DD65DA3B0C2/mvmc_setup.msi
# Import Module
Import-Module "C:\Program Files\Microsoft Virtual Machine Converter\MvmcCmdlet.psd1"
# Pathing
$Path = "C:\Path\To\Directory"
$File = "VM-disk1.vmdk"
ConvertTo-MvmcVirtualHardDisk -SourceLiteralPath $Path\VM-disk1.vmdk -VhdType DynamicHardDisk -VhdFormat VHDX -destination $Path
@mcc85s
Copy link
Author

mcc85s commented Nov 10, 2022

I think there's something wrong with this particular msi application...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment