-
Notifications
You must be signed in to change notification settings - Fork 118
Description
I recently purchased a 4TB NVMe drive to replace my 2TB SATA drive from 2018, and was (technically, still am. it's slow-going) using Clonezilla to migrate my stuff.
I got about 30% of the way through and then the process aborted due to bad sectors.
I went back to Windows, ran a CHKDSK /R (which reads the contents of all files on disk to check for bad blocks) which lasted about 2 hours and reported no errors.
I then re-ran Clonezilla and it again failed at the same point.
After some googling, I found that with the -rescue option, I could look inside /var/log/clonezilla/partclone.log to see which blocks failed.
After figuring out that the numbers in the log file aren't sector numbers, they're byte offsets from the start of the partition, I found that there were 32 bad sectors, in 2 groups of 2 clusters each:
- 139509282-139509283
- 139509286-139509287
However, when I used ntfscluster to locate the files associated with these bad sectors -- so I would know which files needed to be repaired/recovered -- it reported no inodes found!
Even more interestingly:
- I found that clusters 139509281, 139509284-139509285, and 139509288 (the cluster before the first bad one, the two between, and the cluster after) contain a file.
- The same file, in fact.
- It's an audio file from a video game, which means it would have been written all in one go and shouldn't be fragmented.
- I used
ntfsclusterto locate the clusters containing that file, and a very interesting pattern emerged.
This file has seven fragments:
- 635 clusters starting at 139508647 (this ends on 139509281)
- one cluster at ...9439
- one cluster at ...9695
- 2 clusters at ...9284
- one cluster at ...9707
- one cluster at ...9944
- 151 clusters at ...9288
This file is effectively contiguous on disk except for four clusters. Remarkably, the four clusters that are out-of-order coincide with the four clusters that report read errors.
I was originally planning to wipe the old drive and use it as additional (albeit slower) storage space, but I'll leave it intact for now in case you want me to run any test commands.