Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Im kind of freaking out here, if anyone can help me please help me...

This happened to a Windows 2012 KVM virtual machine. I had a very important database running in it, if I could only recover that DB it would be great.

The VM was struggling because it was running out of resources so I decided to transfer it to another node. I used this command to make a backup:

dd if=/var/lib/vz/images/402/vm-402-disk-1.raw | gzip | dd of=/var/lib/vz/images/402/vm-402-disk-1.gz bs=4096

I forgot to shutdown the VM before I executed the command above, so I I tried to stop the DD process, but it was refusing to stop so I killed the process (I know... :/ ). Then I decided to forget about DD and just use the Proxmox's backup tool. Since this backup tool can "stop" the VM before making the backup, I didn't shut the VM down, and asked the backup tool to do it for me.

The backup tool wasnt able to shutdown the VM by itself so the it did not proceeded with the backup.

Then I accessed that VM remotely using VNC and the VM was trying to boot but showing this message: boot failed: not a bootable disk after failed backup

I restarted the VM several times, but it still shows the same message.

I tried to mount the .qcow2 image but I failed. I converted the .qcow2 to .raw, downloaded ntfs-3g so debian could recognize the ntfs partitions and tried to mount the .raw image and it failed too. I tried running both Windows 2012 and Windows 7 isos and tried to repair the Windows installation but both failed too.

Is there any way I could at least access the files inside the image??? I had a firebird database running in it, I just need to recover a 3gb .FDB file so I can restore it in a new VM.

I loaded the Windows 7 ISO and it shows that my drive has 120gb of unallocated space.. does it mean that I lost everything ????????

Linux disk utility shows this: http://d.pr/i/Pu0Y

Is there anything I can do to try to recover the files??

No backup was done since I stopped the DD process, and it seems like I was left with a broken image.. I tried to run a few data recovery programs but none of them worked.. They can find a few files but no more than 8gb, which is usuless to me since it's mostly Windows files..

Please help!

Thanks

share|improve this question
2  
That's a blank disk. Go back to your original raw VM image. –  Michael Hampton Sep 5 '13 at 5:00
    
That is the original VM image. I stopped the DD process, no backup was done. –  viniciusmunich - AssabetTech Sep 5 '13 at 5:05
    
Did you mount it correctly? en.wikibooks.org/wiki/QEMU/Images#Mounting_an_image_on_the_host –  jgillich Sep 5 '13 at 5:16
    
@jgillich, this is what I did pastebin.com/09uNKQz9 –  viniciusmunich - AssabetTech Sep 5 '13 at 5:33

1 Answer 1

I suspect you overwrote your VM image at some point while trying to "recover". Where isn't clear, but that's the most likely way you wound up with a "blank" disk image.

At this point I would run testdisk, followed by photorec. If you get as far as photorec, you will need a second disk to save recovered files onto.

And, in future, I would keep proper backups.

share|improve this answer
    
Thanks Michael, I will try it right now. @Thread: Please if you have any other suggestion, do not hesitate to say it, I will do anything possible to recover this mess I made. –  viniciusmunich - AssabetTech Sep 5 '13 at 5:13
    
No guarantees. If you did overwrite the disk image, you may not get anything back at all. –  Michael Hampton Sep 5 '13 at 5:17
    
Got nothing at all.. :(, testdisk and photorec couldn't even see the drive. fdisk was able to see it though, I'm not sure why. –  viniciusmunich - AssabetTech Sep 5 '13 at 10:39

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.