Honey,I shrunk the HDD. :shock: Bad Disk Geometry

How to use TestDisk to recover lost partition
Post Reply
Message
Author
JPsDad
Posts: 1
Joined: 16 Jul 2013, 19:45

Honey,I shrunk the HDD. :shock: Bad Disk Geometry

#1 Post by JPsDad » 20 Jul 2013, 09:30

My first post so a brief intro.

I am working on my older brother's Dell Optiplex GX620 PentD with a 160GB Seagate He was using Ubuntu 8.04LTS, but after his stroke, he could not remember his passwords. I shrunk his partion and set up Linux Mint 10 in the new space. Now two partitions with two home dir.
Needed Windoze to run a Tax preparation software, so installed WinXP into a small NTFS partition carved out of free space. Booted and configured GRUB and I could chose my O/S. Nice.
Tried Ubuntu 12.04LTS as LiveUSB and it just worked. Clicked on Install .... When the dust settled, I could run U12.04 period, nothing else. Could not boot into any of the other systems.
Now, the sequence of events is hazy. Senior moment, (I am 72yrs young ;-)
I tried Ultimate Boot CD to fix my boot.
I tried Testdisk from PartedMagic, found several of the missing partition, confirmed which were defective and which contained my files. Only after I felt that it was right, I clicked on Write.
I still could not boot. The NTFS sector said that both boot and backup were good:-) However, still cannot boot. should have done dd at this point, but I did not know that yet:-(
I tried several things from UBCD > boot tools.....eventually, I go back to Testdisk. My HDD has shrunk from 160GB to 32GB. It tells me to check my jumpers...
I hve many pages of notes with CHS begin and end and sector sizes and I see that things have changed. From Seagates website, I see CHS of 16383-16-63/512. I am seeing 4111(0r4110;4112)-255-63/4096 using tools like Parted-Magic and Testdisk

There was something about sparce superblocks and I also have handwritten notes to 'repair ext4 using alt superblock,run fsck.ext4 -p -b superblock -B blocksize device' and a list of superblocks: 0,32768, 98304, 163840, 229376, 294912, 819200, 884736,1605632, 2654208 all (alt?) blocksize 4096

Today (using Live Ubuntu 12.04 on a flash drive), I was searching through the Forum postings for similar problems, I saw results from fdisk, so I jumped into terminal > fdisk --help and here is what I got:

root@ubuntu:/# fdisk -l -u /dev/sda

Disk /dev/sda: 160.0 GB, 160000000000 bytes
255 heads, 63 sectors/track, 19452 cylinders, total 312500000 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: 0x00000000

Device Boot Start End Blocks Id System
/dev/sda1 * 48195 234423194 117187500 83 Linux
/dev/sda2 235126784 255609658 10241437+ 7 HPFS/NTFS/exFAT
/dev/sda3 255610215 310440059 27414922+ f W95 Ext'd (LBA)
/dev/sda4 310440060 312496363 1028152 82 Linux swap
/dev/sda5 255610880 306550783 25469952 83 Linux
/dev/sda6 306552393 310440056 1943832 83 Linux

Well, this is looking better, I'm back to 160GB, but how do I use these numbers?

root@ubuntu:/# fdisk -l -u /dev/sda

Disk /dev/sda: 160.0 GB, 160000000000 bytes
255 heads, 63 sectors/track, 19452 cylinders, total 312500000 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: 0x00000000

Device Boot Start End Blocks Id System
/dev/sda1 * 48195 234423194 117187500 83 Linux
/dev/sda2 235126784 255609658 10241437+ 7 HPFS/NTFS/exFAT
/dev/sda3 255610215 310440059 27414922+ f W95 Ext'd (LBA)
/dev/sda4 310440060 312496363 1028152 82 Linux swap / Solaris
/dev/sda5 255610880 306550783 25469952 83 Linux
/dev/sda6 306552393 310440056 1943832 83 Linux

Now, do I put these CHS+B into Testdisk>geometry and then >Analyse and Deeper and IF we locate the real partitions(with files in them) and delete the defective ones and get to a structure where I can see individual files in the /home of Ubuntu and Mint, then and only then I can safely write the partition table???
I already have at least 40 hours of missed sleep trying to figure this out and I cannot lose the /home directories.
Thanks for any help, suggestions, handholding... :?

Sponsored links

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests