Download Microsoft Virtual Machine Converter 3.1 over here.
- Install mvmc_setup.msi
- Run your Powershel 3.0+ as an administrator.
Import-Module “C:\Program Files\Microsoft Virtual Machine Converter\MvmcCmdlet.psd1”
Convert to VHD:
ConvertTo-MvmcVirtualHardDisk -SourceLiteralPath “E:\Virtuele Machines\DC01\DC01.vmdk” -DestinationLiteralPath “G:\Hyper-V” -VhdType FixedHardDisk -VhdFormat Vhd
Convert VHD to VHDX:
Convert-VHD -Path ‘G:\Hyper-V\dc01.vhd’ -DestinationPath “G:\Hyper-V\dc01.vhdx” -VHDType Fixed -Passthru