You are not logged in.

#1 2009-03-27 22:08:57

Berticus
Member
Registered: 2008-06-11
Posts: 731

Restore partition table or recover data

I was putting the cover back on my Antec p180b, and I guess it got stuck and gave it a hard bump (pretty much broke the cover). As a result, one of my hard drives, a Seagate Barracuda ST3750640AS, got messed up or something. All the other hard drives are fine. It's in an LVM with another hard drive, so now I can't boot up into my computer. So I booted into the installation CD:

# find /dev/sd[a-c][1-3]
/dev/sda1
/dev/sda2
/dev/sda3
/dev/sdb1
# find /dev/sdc*
/dev/sdc

This led me to believe the partition was messed up. So I ran cfdisk, and it said something about a missing partition table or something. Additionally, instead of showing the single partition on it, it displays, from my recollection, Pri*Log. To my knowledge, this is the only problem with the hard drive.

So now I need to either somehow create or restore the partition table without overwriting the data. Or get a new hard drive, and some how recover the data (LVM, partitions, and all).

Offline

#2 2009-03-27 22:31:58

evilgold
Member
Registered: 2008-10-30
Posts: 120

Re: Restore partition table or recover data

If you remeber exactly how the partition table looked before you should be able to rewrite it manually with cfdisk without doing any (additional) harm to your data. Failing that you could try using dd(or ddrescue) to image your drive, and attempt to restore it on another disc of equal size.

Offline

#3 2009-03-28 00:32:57

Berticus
Member
Registered: 2008-06-11
Posts: 731

Re: Restore partition table or recover data

I was going to do that, but I wasn't sure if it that would work. Anyway, just tried it, and it didn't work. I tried running vgscan, and it said a certain uuid was missing. I wasn't sure how to check what the current uuid was, so I can't report what it is. Either way, uuid isn't the same. Is there a way to change that?

---Edit---
http://www.linuxquestions.org/questions … nd-362506/

I've also encrypted my hard drive, so using dd may not be an option.

Last edited by Berticus (2009-03-28 01:09:08)

Offline

#4 2009-03-28 01:50:14

carlocci
Member
From: Padova - Italy
Registered: 2008-02-12
Posts: 368

Re: Restore partition table or recover data

Remember: dd if=/dev/sda of=sda.mbr bs=512 count=1 !

You could try:
http://en.wikipedia.org/wiki/Gpart
http://en.wikipedia.org/wiki/TestDisk

Although with an encrypted LVM blabla YMMV

Offline

Board footer

Powered by FluxBB