Messages in this thread | | | Date | Sun, 11 Jul 1999 11:27:41 +0200 (MET DST) | From | Bjorn Wesen <> | Subject | Re: RECOVERY: partition table |
| |
On Sat, 10 Jul 1999, Trever Adams wrote: > I found block lengths etc of my partitions... I accidentally blew away > my partition table (fd0!=hda) and unfortunately I have no way to do a > backup and so have little. The system is still up and running. Is > there anyway I can recreate exactly the same partition table? I imagine
# /sbin/hdparm -g /dev/hda1
/dev/hda1: geometry = 525/128/63, sectors = 2507841, start = 63
do this on all the partitions on your /dev/hda, and write down the start and sectors numbers. With that info, you have enough info to recreate the partition table if you're clever about it.
Remember the numbers are given in sectors, and one cylinder is num_sectors * num_heads (128*63 in the above case), and that the starting offsets are one head into the partition itself..
I haven't looked in /proc if this info is there. Maybe there should be a current partition table entry there ?
/bjorn
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |