diff options
author | Qu Wenruo <quwenruo@cn.fujitsu.com> | 2014-10-30 10:54:03 +0800 |
---|---|---|
committer | David Sterba <dsterba@suse.cz> | 2014-12-04 16:48:13 +0100 |
commit | 0ffacad2906cdb8f62fb56565632160a1a82ad14 (patch) | |
tree | 7534854b9e8a2b820b1591c26e41410cb8b1e28e /cmds-filesystem.c | |
parent | e7c4e700ffa656af4b221a2068b02b391b0ed817 (diff) |
btrfs-progs: rebuild missing block group during chunk recovery if possible
Before the patch, chunk will be considered bad if the corresponding
block group is missing, even the only uncertain data is the 'used'
member of the block group.
This patch will try to recalculate the 'used' value of the block group
and rebuild it.
So even only chunk item and dev extent item is found, the chunk can be
recovered.
Although if extent tree is damanged and needed extent item can't be
read, the block group's 'used' value will be the block group length, to
prevent any later write/block reserve damaging the block group.
In that case, we will prompt user and recommend them to use
'--init-extent-tree' to rebuild extent tree if possible.
Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.cz>
Diffstat (limited to 'cmds-filesystem.c')
0 files changed, 0 insertions, 0 deletions