diff options
author | Gui Hecheng <guihc.fnst@cn.fujitsu.com> | 2013-11-28 13:32:51 +0800 |
---|---|---|
committer | Chris Mason <clm@fb.com> | 2014-01-31 08:22:09 -0800 |
commit | 4989dc82d189494052fed6869b23fb14bd898628 (patch) | |
tree | 69406153314f22cc8639fe099d7625d9fe07cd0e /list.h | |
parent | 7af8e4ee2ad1ffee55be45206515038a3c581c65 (diff) |
btrfs-progs: add chunk-recover raid0/5/6 data stripes rebuild routine
Decide the raid0/5/6 data stripes' order using checksums.
For one chunk, fetch each 64k logical stripe
1. search its checksum in the csum tree
2. read the physical stripe data on each device
3. calc the data checksums
4. if one checksum matches the value from the csum tree,
then the logical stripe resides in that device,
the stripe order index can be calculated.
5. if more than one checksums match,
then use the successive csum in the tree to compare again.
6. if equal stripes are encountered, just fetch next stripe.
7. if some devices' order are still not decided, then they
can not be recovered.
Signed-off-by: Gui Hecheng <guihc.fnst@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Chris Mason <clm@fb.com>
Diffstat (limited to 'list.h')
0 files changed, 0 insertions, 0 deletions