How do I recover files from a corrupt VDI file?
Solution 1
Most of the time a crash while running a VM with VirtualBox will corrupt the profile, not the VDI.
Try making a fresh profile and add the existing VDI as the disk. You could also try a scandisk on the host system if you haven't.
Solution 2
In my case the VDI crashed within a new profile too.
Do the following steps to rescue data:
- create a new profile with your .vdi to rescue as a harddisk
- download a linux live CD (like puppy, xubunu...) and add it as a live-cd image to the new profile
- start the VM
- mount the .vdi file (in my case it was sda2) and rescue your files as you like (send them as email to yourself)
have fun
Related videos on Youtube
Comments
-
Eric Packwood over 1 year
Is it possible to repair a corrupt VDI file? The OS on the VDI (XP) doesn't boot at all, it just hangs at a black screen. I was getting file errors before on its last boot, but now its not working at all.
Sector viewer shows 'Invalid partition table Error loading operating system Missing operating system'. I tried mounting the file from the host OS, but it just says that the drive isn't formatted. I don't need to be able to run the VDI, but I do need some files that are on it.
Is there any way to recover files from the corrupt VDI file?
-
madmaze over 13 yearslast time you ran the VM was it shut down correctly?
-
Cheeto over 13 yearsCan you boot it with an ISO then either repair the OS installation or retrieve your files?
-
-
user727382 about 12 yearsCan confirm this worked for me. Created a new VM using the same VDI. Up and running again.
-
VitOne over 9 yearsWell I'll be damned this actually worked.
-
Eamorr about 9 yearsThis worked for my. I kept getting "read only" errors when trying to boot my VM. After several attempts, I switched it off and created a new VM with the troublesome VDI image. I was able to boot up! Then I shut down cleanly, and rebooted the broken VM - everything worked again!!!
-
Tim over 8 yearsIn my case, I just removed the problematic VHD disk and then added it again. Worked. Runned scandisk and other tools just for sure.
-
Peter Wippermann about 8 yearsHe "plugged" the VDI hard drive into a Linux OS and copied all the files he would still need. Then he setup a fresh new Windows XP installation and copied the files he had just rescued before.
-
Mike Robinson about 8 yearsI have also seen this to be a "false alarm!" Quite recently, VirtualBox ominously told me that the main-hard-drive VDI file of a Linux VM was "unavailable," and yet the VM subsequently booted just fine. There was, in fact, nothing wrong with the disk at all.