(original article)

Re: Road map for md/raid driver - sort of

14 April 2009, 08:31 UTC

I don't think I'm proposing the remapping of bad blocks. Just recording their location. If you get a read error on a degraded array, you need to either record the location of that bad block, or fail the whole array. Some people prefer the first option.

The background task you suggest is already quite possible. If you echo repair > /sys/block/mdX/md/sync_action it will read the whole array and attempt to fix any read errors. By default it will limit itself to 1 Megabyte per second if there is other activity on the devices. If you think this in not "background" enough, you can set a lower minimum with e.g. echo 100 > /sys/block/mdX/md/sync_speed_min

Irrepairable damage will currently kick the bad drive from the array as there is no other real option. When we get support for storing a bad-block list, irrepairable damage will be recorded in the bad block list. It seems likely that we will then get "mdadm --monitor" to report that in whatever way it has been configured to report thing.




[æ]