Hi.
I'm not sure how to deal with this problem. I really want to recover my partition if possible. any suggestions are welcome.
irrelevant background: I upgraded my linux partition the other day. Debian squeeze --> wheezy. (some day I'll switch to Ubuntu, probably.) All was well. everything was working great. yesterday, when I attempted to reboot however, instead of the standard Grub, I got a "grub rescue> " prompt. To make a long story short... I had to get a rescue, live image on a usb stick which allowed me to boot and debug.
It appears that I have some bad blocks on my HD, and those bad-blocks just happen to span a partition boundary... twixt: sda2 and sda3. my partitions are listed below. sda2 is my swap partition, so there's nothing to worry about. I resize it and do a mkswap (or whatever). The big problem is that sda3 is the partition I boot from and is the partition where I have grub installed. And, as far as I can tell, it seems that by losing the first 4 (or so) 512-byte blocks on this partition, that I have lost my grub config. I'm worried also that... traditionally anyway, there are usually a host of important items located right at the front of a bootable partition. the kernel, for instance, I think at least used to be located there. Worst of all, perhaps... I suspect there may be some critical information about the filesystem itself embedded right at the beginning of a partition that contains an ext3/4 filesystem. I certainly could be wrong about this, but the "beginning" of a binary thing is a logical place to store a header (a structural meta-information thing, like a TCP/IP packet header, for instance).
I really want to save this filesystem, but I'm not sure how to go about it. I will continue to research, and I have really only just begun to do that, but I want to get this done quickly if I can. if anyone has a suggestion please let me know. Thank you!!
Ana
root@debian:/home/ana# fdisk /dev/sda
Command (m for help): p
Disk /dev/sda: 160.0 GB, 160041885696 bytes
214 heads, 54 sectors/track, 27049 cylinders, total 312581808 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x9358c633
Device Boot Start End Blocks Id System
/dev/sda1 * 2048 151129367 75563660 7 HPFS/NTFS/exFAT
/dev/sda2 151129368 155035295 1952964 82 Linux swap / Solaris
/dev/sda3 155035296 312497351 78731028 83 Linux
/dev/sda4 312497352 312578243 40446 ef EFI (FAT-12/16/32)