After a power outage my laptop fails to boot. I investigated the matter with a bunch of disk utilities and live CDs. The data is intact, and I made a backup copy of it. Nevertheless I'd like to restore the disk functioning, including booting of course, with as minimal efforts as possible. I know many experts suggest to recreate partitions anew, restore operating system anew, and reinstall software anew. This is hardly doable in my case (I don't even have all distribution kits). This is why I'd like to edit corrupted partition table in-place, and I need an advice which part exactly is problematic.
The disk contains 2 volumes: one is primary partition and the other is a logical drive in extended partition.
When I boot the laptop from a live CD, Windows sees both drives, but the logical drive in the extended partition is inaccessible.
diskpart
's command list volume
shows that the volume fs flag is RAW instead of NTFS. The odd thing is that disk utilities which I used to restore data (including DMDE) see this volume as NTFS and read data from it without problems.
Here is the output of diskpart:
And here's what DMDE shows:
The question is which raw bytes and how should I edit in the table (I can use DMDE for direct disk edition, for example) to make the volume proper NTFS accessible from Windows?
I'm not sure which other details may be important and ready to provide them upon request.
Update
The only one real answer among the linked ones suggests using TestDisk. First, I must say that this utility is very picky about OS - it does not run on any WinPE based live CD I tried. Finally I managed to run it on [almost] fully fledged Win7 live CD. Here is what it shows (please note NTFS in the logical volume in the extended partition):
and (please note FAT32 this time):
I need to recover the largest volume from here. It's displayed as FAT32 under TestDisk (DMDE shown NTFS). P
command does not produce a readable list of files for this volume. I tried the T
command to change type to NTFS, but this did not solve the problem: P
still lists a garbage ("file system may be damaged"). Yet I see the full filesystem under DMDE and saved it using r.saver utility.
I ran a deeper search:
and found:
The Deleted NTFS volume is the actual drive with my data. Then I changed its from 'D' to 'L' and did Write changes to the disk and reboot.
The drive is still inaccessible, but now if I run DMDE it complains that MBR records require a disk of at least 625153410 LBA (320GB), but the disk is 625142448 LBA (320GB).
From my experience either TestDisk is incapable of doing the job in my case, or I need more detailed instructions what exactly to fix using TestDisk.
Thanks in advance.
As a small remark I must say that TestDisk is buggy: i made a backup of the partition table by corresponding TestDisk's command, then changed the table and wrote it to the disk; then discovered that the changes did not help and decided to rollback the changes from the backup - as a result I got completely different and incorrect partition table. The only thing that saved me from a fiasco was that I made another backup using dmde, which restored the structure as expected.