diff options
author | NeilBrown <neilb@suse.de> | 2012-10-03 09:07:11 +0200 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2012-10-03 09:07:11 +0200 |
commit | bf95d0f38cd35c01a258771bcc9e55b078e0726c (patch) | |
tree | 38b630e5a43bc4269badc7ebfcf4e60831d23d29 /md.4 | |
parent | Grow: make warning about old metadata more explicit. (diff) | |
download | mdadm-bf95d0f38cd35c01a258771bcc9e55b078e0726c.tar.xz mdadm-bf95d0f38cd35c01a258771bcc9e55b078e0726c.zip |
Bad block log
Diffstat (limited to 'md.4')
-rw-r--r-- | md.4 | 28 |
1 files changed, 28 insertions, 0 deletions
@@ -551,6 +551,34 @@ intent log if one is present. In 2.6.13, intent bitmaps are only supported with RAID1. Other levels with redundancy are supported from 2.6.15. +.SS BAD BLOCK LOG + +From Linux 3.5 each device in an +.I md +array can store a list of known-bad-blocks. This list is 4K in size +and usually positioned at the end of the space between the superblock +and the data. + +When a block cannot be read and cannot be repaired by writing data +recovered from other devices, the address of the block is stored in +the bad block log. Similarly if an attempt to write a block fails, +the address will be recorded as a bad block. If attempting to record +the bad block fails, the whole device will be marked faulty. + +Attempting to read from a known bad block will cause a read error. +Attempting to write to a known bad block will be ignored if any write +errors have been reported by the device. If there have been no write +errors then the data will be written to the known bad block and if +that succeeds, the address will be removed from the list. + +This allows an array to fail more gracefully - a few blocks on +different devices can be faulty without taking the whole array out of +action. + +The log is particularly useful when recovering to a spare. If a few blocks +cannot be read from the other devices, the bulk of the recovery can +complete and those few bad blocks will be recorded in the bad block log. + .SS WRITE-BEHIND From Linux 2.6.14, |