How to Repair Corrupt and Damaged VHD File

f your VHD file got corrupted or damaged and you want to repair it. Then you are at right place just either perform the simple manual method or try professional VHD Data Recovery Software. The listed methods are widely used and trusted. Try the solution and repair VHD file without using the software.

Methods to Repair VHD File

As we know that the VHD stands for Virtual Hard Disk and it stores very crucial data. In any situation, your .vhd file gets corrupted and inaccessible. Then you have two options, either repair VHD file by PowerShell command or repair damaged VHD file by creating the virtual server. Let’s discuss both methods in detail.

Method 1: – Repair Damaged VHD File By PowerShell Command

PowerShell empowers the user to automate the process. But the commands are hectic to use if you are not familiar with formats of commands. So I recommend you to first take backup and then execute the PowerShell command to repair corrupt VHD file. Run the command on PowerShell CMD:

  1. Choose what VHD we want to mount $VHDName = “V:\serverx.vhd
  2. Get the MSVM_ImageManagementService
  3. $VHDService = get-wmiobject -class “Msvm_ImageManagementService” -namespace “root\virtualization” -computername “.”
  4. Now execute this command to mount vhd file
  5. $Result = $VHDService.Mount($VHDName)

Note: – After performing these command successfully. Check whether the VHD file corruption issue is fixed or not. If your corrupted VHD file repaired successfully then access your data otherwise move to method 2.

Method 2: – Repair Corrupt VHD File by Creating Virtual Server

The user can also repair corrupt VHD file by creating new virtual machine and after that link or add the damaged VHD file to the newly created virtual machine and then compact it. To complete this process performs the steps listed below:

  1. First, create the new virtual server and attach new hard disk.
  2. Now click on Setting and add newly created hard disk. After that browse the VHD file in it.
  3. Here hit on Virtual Disk Wizard and then select the Compact option. There should be Convert it to a Fixed Size Virtual hard Disk check-box checked.
  4. At the end Save this VHD file by new name. You can also save by original file name.

Note: – Apart from these manual methods to repair corrupt VHD file you can also the VHD TOOL provided by Microsoft. Just download the tool from Microsoft official website and then repair corrupt and damaged VHD file easily.

Final Words!!

I hope this article will help end user to repair damaged and corrupt VHD file manually.