I have a 2Tb failing HDD which I partially recovered using DDRESCUE.
Final result was 1653 Gb Recovered, 346 Gb unreadable, 1398 bad areas.
Tried to run NTFSFINDBAD to find out which files had been totally recovered and which ones only partially recovered.
On the recovered drive, I run Fdisk with foll. output
fdisk -lu /dev/sdb
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders, total 3907029168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x921383e0
Device Boot Start End Blocks Id System
/dev/sdb1 2048 3907026943 1953512448 7 HPFS/NTFS/exFAT
Then tried to run (again on the recovered drive, not on the failing drive) ntfsfindbad, with following result:
ddru_ntfsfindbad /dev/sdb1 ~/Desktop/rescued_logfile -i 1048576
ddru_ntfsfindbad 1.4 20141014
Reading the logfile into memory...
Reading boot sector...
ERROR! This program only allows for 8 sectors per MFT record, and this partition reports 7474
ERROR! Unable to correctly process the boot sector
Assume that was happened is that the MFT was corrupted in the failing drive and copied the corrupt MFT into the rescue drive, is this correct? however, the rescued drive seems fine with files accesible.
Any indication how should I proceed? Should I run chkdsk /f to try repair the MFT? (sorry I am a windows user)
I would appreciate any help. Thanks beforehand
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Your command:
ddru_ntfsfindbad /dev/sdb1 ~/Desktop/rescued_logfile -i 1048576
should be using /dev/sdb, NOT /dev/sdb1.
The whole reason to find the partition offset is to locate it based on the start of the whole drive, as that is how you did the recovery. You are supplying the offset but also using the partition as the base location, so it is looking in the wrong spot for the partition boot sector. If it can't process the partition boot sector, it can't find the MFT. I will have to look at my code, as I thought it should check for the NTFS signature first and report that as an error which may make more sense to someone.
And good luck with that recovery. 346 GB is a large error size.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thank you very much for your reply. Using the command as instructed by you, ntfsfindbad run perfect.
Unfortunately, disk is so damaged that recovery prospects, even with luck, are scarce.
One last question, is there any easy way to convert the inode (as reported by ntfsfindbad log) into sector numbers? if affirmative I could concentrate on trying to recover files with few sectors damaged and forget about the rest.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Actually there is a way. Look at the documentation for the --debug option for ddru_ntfsfindbad. It will produce an output that includes the offset and size for every piece of an inode. I have included a small sample of the output below. Note that inodes can have more than one part (indicated a fragmented file). You can use the fulloffset as the --input-offset and the size as the --size for custom ddrescue commands to focus on specific files. Make sure to keep using the same logfile you have been for all your commands.
Using this sample, say we wanted to focus on recovering inode 819 which has 4 fragments that have errors. You would use commands similar to the following, making sure to include the "0x" in the number (so it knows it is a hex number).
Very concise and helpful reply.
Before asking I have been searching in Google for quite some time but I didn't find any information I could make practical use of.
Once again, thanks for your time and for sharing your knowledge!!!!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thanks for your toolkit!
Having read the topic, I have an idea:
Can you please extend the output format of debug file or somehow automate the process of creating a domain_mapfile to run ddrescue, to get an example of such a type:
I have a similar situation. HDD_size=3Tb, still pending_to_rescue=212Gb. Some files are damaged only a little, some are not needed (present in other drives), so I would like to analyse the situation to maximize the recovery before the drive goes to the seller while it still has warranty.
As for now, I am unable to see any list at all. 7680 inodes; 181000 lines of ddrescue_mapfile, 512M of RAM, 200 M of free space on system drive, Lubuntu 16.04 LTS.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have a 2Tb failing HDD which I partially recovered using DDRESCUE.
Final result was 1653 Gb Recovered, 346 Gb unreadable, 1398 bad areas.
Tried to run NTFSFINDBAD to find out which files had been totally recovered and which ones only partially recovered.
On the recovered drive, I run Fdisk with foll. output
fdisk -lu /dev/sdb
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders, total 3907029168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x921383e0
Device Boot Start End Blocks Id System
/dev/sdb1 2048 3907026943 1953512448 7 HPFS/NTFS/exFAT
Then tried to run (again on the recovered drive, not on the failing drive) ntfsfindbad, with following result:
ddru_ntfsfindbad /dev/sdb1 ~/Desktop/rescued_logfile -i 1048576
ddru_ntfsfindbad 1.4 20141014
Reading the logfile into memory...
Reading boot sector...
ERROR! This program only allows for 8 sectors per MFT record, and this partition reports 7474
ERROR! Unable to correctly process the boot sector
Assume that was happened is that the MFT was corrupted in the failing drive and copied the corrupt MFT into the rescue drive, is this correct? however, the rescued drive seems fine with files accesible.
Any indication how should I proceed? Should I run chkdsk /f to try repair the MFT? (sorry I am a windows user)
I would appreciate any help. Thanks beforehand
Your command:
ddru_ntfsfindbad /dev/sdb1 ~/Desktop/rescued_logfile -i 1048576
should be using /dev/sdb, NOT /dev/sdb1.
The whole reason to find the partition offset is to locate it based on the start of the whole drive, as that is how you did the recovery. You are supplying the offset but also using the partition as the base location, so it is looking in the wrong spot for the partition boot sector. If it can't process the partition boot sector, it can't find the MFT. I will have to look at my code, as I thought it should check for the NTFS signature first and report that as an error which may make more sense to someone.
And good luck with that recovery. 346 GB is a large error size.
Thank you very much for your reply. Using the command as instructed by you, ntfsfindbad run perfect.
Unfortunately, disk is so damaged that recovery prospects, even with luck, are scarce.
One last question, is there any easy way to convert the inode (as reported by ntfsfindbad log) into sector numbers? if affirmative I could concentrate on trying to recover files with few sectors damaged and forget about the rest.
Actually there is a way. Look at the documentation for the --debug option for ddru_ntfsfindbad. It will produce an output that includes the offset and size for every piece of an inode. I have included a small sample of the output below. Note that inodes can have more than one part (indicated a fragmented file). You can use the fulloffset as the --input-offset and the size as the --size for custom ddrescue commands to focus on specific files. Make sure to keep using the same logfile you have been for all your commands.
Using this sample, say we wanted to focus on recovering inode 819 which has 4 fragments that have errors. You would use commands similar to the following, making sure to include the "0x" in the number (so it knows it is a hex number).
ddrescue -f /dev/sda /dev/sdb rescued_logfile -i 0xA1E70000 -s 0xBA8000
ddrescue -f /dev/sda /dev/sdb rescued_logfile -i 0xA8404000 -s 0xF24000
ddrescue -f /dev/sda /dev/sdb rescued_logfile -i 0xA96C5000 -s 0xC63000
ddrescue -f /dev/sda /dev/sdb rescued_logfile -i 0xD900F000 -s 0x523800
FYI
Picture files can sometimes survive a few small errors with little to no noticeable affect, although that is not always the case.
Video files can often handle a few small errors and only have small glitches.
Microsoft Office documents don't handle errors very well at all and will probably not even open and will likely not be able to be repaired.
All other types of documents/files are at the mercy of whatever program opens them.
Very concise and helpful reply.
Before asking I have been searching in Google for quite some time but I didn't find any information I could make practical use of.
Once again, thanks for your time and for sharing your knowledge!!!!
Thanks for your toolkit!
Having read the topic, I have an idea:
Can you please extend the output format of debug file or somehow automate the process of creating a domain_mapfile to run ddrescue, to get an example of such a type:
I have a similar situation. HDD_size=3Tb, still pending_to_rescue=212Gb. Some files are damaged only a little, some are not needed (present in other drives), so I would like to analyse the situation to maximize the recovery before the drive goes to the seller while it still has warranty.
As for now, I am unable to see any list at all. 7680 inodes; 181000 lines of ddrescue_mapfile, 512M of RAM, 200 M of free space on system drive, Lubuntu 16.04 LTS.