tech-kern archive

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

Re: RAIDframe and bad blocks



On Fri, 20 Sep 2019, Emmanuel Dreyfus wrote:
Consider a RAID 1 with wd0 and wd1

wd1 has bad blocks and is marked failed. I replace it and reconstruct
the RAID with a new disk. But wd0 also has bad blocks, and RAIDframe
will give up reconstruction because of the read failure.

Most likely the relevant blocks are oustide of used space, and could
just be replaced by zeroes, but that needs to be done by cloning
with dd conv=noerror,sync, with the RAID offline.

Perhaps we could come up with a better RAIDframe behavior on
reconstruction with read errors?

I wrote a tool I called diskfix which scan reads a given block device in 1MB sections. If it gets an I/O error, it then scans the same section sector by sector and on encountering a sector I/O error, writes the sector back. I usually use it on the failed component (in your example, wd1) before initiating a reconstruction, but if you are brave/desperate it can be run on a live filesystem/RAIDframe array.

--
Stephen



Home | Main Index | Thread Index | Old Index