summaryrefslogtreecommitdiff
path: root/rbtree.c
diff options
context:
space:
mode:
authorHidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>2013-09-05 15:55:08 +0900
committerChris Mason <chris.mason@fusionio.com>2013-10-16 08:20:42 -0400
commit49fef6fc53f79aaa2e8e0c601a2482545b6c2486 (patch)
treef38e88545966b25322289dc563e39b09c49277d2 /rbtree.c
parentf9d102efdc87f9c142157f16e443fb2c610c5317 (diff)
btrfs-progs: error if device have no space to make primary chunks
The previous patch works fine if the size of specified volume to mkfs is less than 4MB. However usually btrfs requires more than 4MB to work, and the minimum preferred size is depending on the raid setting etc. This patch let mkfs print error message if it cannot allocate one of chunks should be there at first. [before] # truncate --size=4500K testfile # ./mkfs.btrfs -f testfile : SMALL VOLUME: forcing mixed metadata/data groups mkfs.btrfs: mkfs.c:84: make_root_dir: Assertion `!(ret)' failed. Aborted (core dumped) [After] # truncate --size=4500K testfile # ./mkfs.btrfs -f testfile : SMALL VOLUME: forcing mixed metadata/data groups no space to alloc data/metadata chunk failed to setup the root directory TBD is calculate minimum size for setting and put it in the error message to let user know how large amount of volume is required. Signed-off-by: Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz> Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Diffstat (limited to 'rbtree.c')
0 files changed, 0 insertions, 0 deletions