Recovering Corrupted VMware Disk Images

Want to support HowtoForge? Become a subscriber!
 
Submitted by SamTzu (Contact Author) (Forums) on Tue, 2008-04-22 11:42. :: VMware | Virtualization

Recovering Corrupted VMware Disk Images

Many a time I cursed and vailed because VMware had let me down. Here is a "quick" and dirty way to access your corrupted VMware server/workstation .vmdk files.

Here is how I managed to recover Zimbra mail servers "mail folders" (Ubuntu6/ext3) from corrupted VMware server image using WindowsXP, VMware Server, Ken Kato's "Virtual Disk Driver for Windows NT platform" & Diskinternals Linux reader.

1) Copy corrupted .vmdk file to your WindowsXP workstations c:\temp folder. My filename was Opt.vmdk - I had to use WinSCP without any compression on the Linux side to copy it to Windows.

2) Download Ken's "Virtual Disk Driver" (VDK) and extract it to c:\temp folder. (Freeware) - http://chitchat.at.infoseek.co.jp/vmware/vdk.html

3) Type

CMD

in the "Run" on Windows to start the "Command Prompt".

4) Change to the folder where vdk.exe is located using

cd c:\temp

command.

5) Type

vdk start

6) Type

vdk open 0 <diskfile> /L:R:

-My command was

vdk open 0 Opt.vmdk /L:R:

<diskfile> has to be substituted by the vmdk file. In my case it was the opt.vmdk file which then was mounted. /L:R: = Mount it as drive R:.

7) Now you probably have the disk mounted on your Windows PC. Problem is that your Windows does not understand Linux formated drives yet.

8) Download and install "Disk Internals Linux Reader." (Demoversion.) - http://www.diskinternals.com/download.shtml#cd

9) When I started the Linux Reader it crashed, but I just ignored that and continued. It was still able to find my mounted Linux drive. After scanning the drive in vain I cancelled all the scans and just proceeded to restore the folders it found to the Windows local hard drive.

Hope this helps. VMware Server's own recovery/mount tools did not work out well for me.

Sami Mattila
http://www.mattila.eu
 


Please do not use the comment function to ask for help! If you need help, please use our forum.
Comments will be published after administrator approval.
Submitted by Cam (not registered) on Sat, 2009-10-10 07:37.

Followed the steps and it worked perfectly for me.  I was able to rescue all my important files :)

Thanks a million!