Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top


Thanks everybody, the MBR schema now is restored via TestDisk, and thanks to the author for this piece of software.

I wanted to format only my Data (NTFS) partition for a fresh start. But I ended up partitioning my whole disk from MBR to GUID structure and now all my partitions are gone.

I had a Ubuntu/Windows setup with MBR structure and lots of partitions and few of them where truecrypt partitions.

Please help, I am in huge trouble, lost all my wedding pictures, account logins. Can I get my data back?

Sorry if already answered, but I am kinda lost right now and I apologize.

share|improve this question
If I understand correctly you've wiped the whole drive? And there's nothing left on it? If this is the case then there's lots of data recovery sotware that can recover files from wiped hard drives. – Merri Jan 11 '13 at 14:32
please clarify what commands/tools you used to do the format/wipe - if it was only the partition table, then it's easy to recover - if you've actually re-built the filesystems, it will be hard(maybe impossible). – ImaginaryRobots Jan 11 '13 at 14:35
Ofcourse I do hope you get your pixs back but let this be a lesson... if those files are so darn important next time start by making a BACKUP. Heck, why do you not make regular backups of your personal stuff!? What would you do if the hard disc crashed and became unusable? – Rinzwind Jan 11 '13 at 14:41
Oh: nobody said so but STOP using that disc. Do not do anything that can change the disc content. Some hopefully helpful links:… and You need to use external tools for this (so something like a live cd or a recovery cd) – Rinzwind Jan 11 '13 at 14:43
Sorry for the delay, I had to run in panic to the mall for a new disk. @atAll Steps that resulted in empty disk: Ubuntu LTS 12.04 > disk utility > highlighted my "Data" NTFS partition under section "Volumes" > pressed "Format Drive" > selected "GUID Partition Table" > pressed on "Format". I was wrongly thinking, that it would only effect my highlighted partition/volume. Currently: The disk is now partitioned as GUID Partition Table, and has no partitions at all. It's totally free. But this process was extremely quick, so I hope no overwrite. Disk is not in use, I am using a live-cd. – User Jan 11 '13 at 17:58
up vote 1 down vote accepted

This may help you, although I will profess to not being an expert in the MBR, TrueCrypt etc. :

EDIT: following on from Web-E's comment, this link refers to the use of TestDisk to rebuild the partition table:

"TestDisk ( can be used to rebuild MBR / partitions (available in SystemRescueCd (, which seems to be a good distro for system rescue.)"

share|improve this answer
this restore bootloader not mbr partition table. – Web-E Jan 11 '13 at 15:17
So currently by accident my partitioning schema is GUID, it used to be MBR, and now how should I go about to recover my old MBR schema? Should re-partition back to MBR and than try to recover? Or let it stay as GUID and try to recover my MBR schema from it? I am really lost. Thank you to all and everybody for their help. – User Jan 11 '13 at 18:15
Currently trying TestDisk on a dummy replica, on which I performed the same steps as to test it out before doing any real work on actual drive. Thanks, let you know. – User Jan 14 '13 at 23:06
  1. CALM DOWN, do not rush, do not blindly run any tools trying to fix things.
  2. STOP using the disk. Make sure you don't write a single byte on it
  3. If the data is really valuable, consider using professional help - there are organizations which commercially restore data on hard drives, they'll certainly do better than you
  4. Get a hard drive bigger that the stuffed one, make a binary copy of the drive's data. Or better two. This may take a while. Ideally, all further operations should be on the "mirrors" of your drive, not on the live data.
  5. Try using TestDisk as already has been advised. Here's an article illustrating how to recover a damaged MBR using TestDisk, the key part is to use "Analyze current partition structure..." option - however, I would suggest to operate on a data snapshot, not on a live drive.

enter image description here

Basically, if you read Wikipedia articles on MBR and GPT you'll see that the whole problem is caused by the GPT replacing 4 primary partition records in the MBR with a "fake" partition type EEh. Each primary partition record is 16 bytes, so the total damage is likely to be just 64 bytes, you could've just edited the data by hand in a hex editor if you knew exactly what the partitions were.

share|improve this answer
1. I am trying -thanks 2. Done 3. I shall research the options 4. Done, got a bigger one. But I still need to write a .dd image file to it the new bought drive, currently trying to figure out how to do that. 5. I shall do that, after the image is created. Yes it looks like only the partitioning schema table is overwritten, and the actual partitions should be there. I know the partition sizes in rough GB only, not in bytes. I'll keep you all updated, after I have created the .dd image file. Hoping I don't have to tell at home what happened to our disk. – User Jan 11 '13 at 21:14
2 spaces or <br/> did not work for me, I am new to this site, so sorry. Wanted to format, but could not. – User Jan 11 '13 at 21:19
shall try the link but dd is taking it's time, and there is no way I can know how far it is. Thanks. – User Jan 11 '13 at 21:34
Thanks @Sergey, Clive, Merri, ImaginaryRobots, Rizwind, Web-E, don't know if this is wrong or not on this site. But thanks, keep you all updated later. – User Jan 11 '13 at 23:42

Your Answer


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.