Photorec stuck in cyclic reading
Posted: 10 Feb 2013, 22:44
I am trying to use Photorec to recover files from a failing 250 GB NTFS-formated Lacie hdd. The hdd has a bunch of bad sectors so I made an image of it with ddrescue and managed to save everything except 94 kB. I tried to use TestDisk to recover the filesystem but it seems to have been lost. So, I started running Photorec on the image with default settings and things seemed to be working fine. The files were ticking in and the estimated time of completion seemed reasonable. But after having gone through approximately 218,000,000 of the 488392002 sectors and discovered 25,000+ files it got stuck in a frustrating behavior.
The sector number will scan up to approximately 218,630,000. Then it freezes for a while (during the freeze there is no activity from the second hdd which holds the image, but instead the Photorec process consumes all the cpu speed). Then the sector number jumps to a higher number, the number of files found increases by one and the sector number goes back down to approximately 217,170,000 and starts scanning up again. This pattern repeats itself over and over again. Each cycle takes approximately 3.5 minutes and only one new file is found each time. This has now been going on for well over 24 hours. The higher sector number that is only jumped to very briefly after the freeze is slowly increasing and right now it's up to approximately 220,000,000.
From reading the answer to another question in this forum I figured out that the explanation is probably this: After each file Photorec finds it is trying to piece together a large previously found fragment with whatever comes after the newly found file. This means the large file fragment is read over and over again and only a small fraction of the time is spent reading new data. Does this explanation seem reasonable? If so, is it likely that Photorec will ever piece together the fragment and continue normally? Is there any way I can prevent Photorec from behaving like this? Right now, I estimate that it will take 50-100 days to scan the rest of the image in this fashion. I really don't have time to wait that long.
The sector number will scan up to approximately 218,630,000. Then it freezes for a while (during the freeze there is no activity from the second hdd which holds the image, but instead the Photorec process consumes all the cpu speed). Then the sector number jumps to a higher number, the number of files found increases by one and the sector number goes back down to approximately 217,170,000 and starts scanning up again. This pattern repeats itself over and over again. Each cycle takes approximately 3.5 minutes and only one new file is found each time. This has now been going on for well over 24 hours. The higher sector number that is only jumped to very briefly after the freeze is slowly increasing and right now it's up to approximately 220,000,000.
From reading the answer to another question in this forum I figured out that the explanation is probably this: After each file Photorec finds it is trying to piece together a large previously found fragment with whatever comes after the newly found file. This means the large file fragment is read over and over again and only a small fraction of the time is spent reading new data. Does this explanation seem reasonable? If so, is it likely that Photorec will ever piece together the fragment and continue normally? Is there any way I can prevent Photorec from behaving like this? Right now, I estimate that it will take 50-100 days to scan the rest of the image in this fashion. I really don't have time to wait that long.