Re: using dd (or dd_rescue) to salvage array

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 05.02.2012 20:10, Keith Keller wrote:
On 2012-02-04, Stefan /*St0fF*/ Hübner<stefan.huebner@xxxxxxxxxxxxxxxxxx>  wrote:
actually, ddrescue is THE WAY TO GO in this case.  Don't use the old
ddrescue, but the GNU version.  Some distros call it gddrescue, on
gentoo the old one is called dd-rescue and the gnu-one ddrescue.  Just
check it out: http://www.gnu.org/software/ddrescue/ddrescue.html
Thanks for the advice, Stefan.  Frustratingly enough, I will get a
chance to try GNU ddrescue despite my impatience--I originally used
dd_rescue to try to get an image of the failing drive, and while that
succeeded just fine (only lost 8k), the target ended up reporting ECC
errors during the rebuild!  So I've taken a new image with ddrescue
to a tested drive (again, losing 8k), and am hoping that it goes better.
(At the moment I'm just attempting a one-spare rebuild, which I'm hoping
will go faster than a two-disk build, and therefore report any problems
sooner.)

I realized after reading my initial post that I wasn't 100% clear what I
was asking.  I knew that some sort of dd would work, but I'd only done
it before in a filesystem context, and didn't know how mdraid would
react.  So I am curious, does anyone know what I might expect when the
rebuild gets to the part on the new image where the data was lost?  Will
it just create a problem on the filesystem, or might something worse
happen?  Should I run a check if the rebuild completes successfully?
And will mismatch_cnt get populated by the rebuild, or would I need a
check to expose mismatches?

--keith

From the logical point of view those lost 8k would create bad data - i.e. a filesystem problem OR simply corrupted data. That depends on which blocks exactly are bad. If you were using lvm it could even be worse, like broken metadata.

It would be good if those 8k were "in a row" - that way at max 3 fs-blocks (when using 4k fs-blocksize) would be corrupted. If you're lucky, you won't even notice - like me: my system SSD broke down lately. I ddrescued as much as I could, but around 250k are gone. I'm dual-booting windows and gentoo and I have not yet encountered a problem from the missing data. Lucky me...

Cheers,
Stefan
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux