Hyper-V

How to convert Hyper-V VHDX file to VHD using PowerShell

How to convert Hyper-V VHDX file to VHD using PowerShell

If you have a VHDX file and you want to make it compatible with some other virtual machine that supports VHD format, then this post shows, how you can convert the Hyper-V VHDX file to VHD using Windows PowerShell so that you can run it without any problem.

VHDX format was introduced with a lot of flexibility. The primary difference between VHDX and VHD is the storage limit. The standard storage limit of VHD is 2 TB, whereas VHDX has a storage limit of 64 TB. Although they do the same job, people can use them for different purposes. If you have a VHDX file and you want to make it compatible with some other program by converting it to VHD, you can use Windows PowerShell.

Convert VHDX file to VHD using PowerShell

To convert the Hyper-V VHDX file to VHD using Windows PowerShell, follow these steps.

Note down the VHDX file's location first. You cannot perform this task without the .vhdx file. Following that, you have to open the Windows PowerShell with administrator privilege. For that, press Win+X, and select Windows PowerShell (Admin).

Execute the following command-

Convert-VHD -Path C:\Users\\Desktop\win8.vhdx -DestinationPath C:\Users\\Desktop\win8.vhd

Do not forget to replace the with the actual username. Also, replace win8 with the name of your file. The path assumes that your VHDX file is located on the desktop, and you want to save the VHD file on the desktop. You will have to change the paths suitably in your case.

Convert VHDX file to VHD using PowerShell

If you have a VHD file and you want to convert it to VHDX, you can use the same command in Windows PowerShell.

Convert-VHD -Path C:\Users\\Desktop\win8.vhd -DestinationPath C:\Users\\Desktop\win8.vhdx

It is possible to choose between Dynamic and Fixed disk type. For that, it is recommended to use -VHDType Dynamic and -VHDType Fixed switches while converting the file.

If you are not able to use this command or you are facing errors in Windows PowerShell, you need to enable Hyper-V and then use the command again.

Middle mouse button not working in Windows 10
The middle mouse button helps you scroll through long webpages and screens with a lot of data. If that stops, well you will end up using the keyboard ...
How to change Left & Right mouse buttons on Windows 10 PC
It's quite a norm that all computer mouse devices are ergonomically designed for right-handed users. But there are mouse devices available which are s...
Emulate Mouse clicks by hovering using Clickless Mouse in Windows 10
Using a mouse or keyboard in the wrong posture of excessive usage can result in a lot of health issues, including strain, carpal tunnel syndrome, and ...