mirror of
https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git
synced 2024-11-24 02:25:03 +08:00
e228d700d5
Teach e2fsck to (re)construct extent trees. This enables us to do either of the following: compress a highly sparse extent tree into fewer ETB blocks; or convert a ext3-style block mapped file to an extent file. The reconstruction is performed during pass 1E or 3A, as detailed below. For files that are already extent based, this algorithm will automatically run (pending user approval) if pass1 determines either (1) that a whole level of extent tree will fit into a higher level of the tree; (2) that the size of any level can be reduced by at least one ETB block; or (3) the extent tree is unnecessarily deep. It will not run at all if errors are found and the user declines to fix the errors. The option "-E bmap2extent" can be used to force e2fsck to convert all block map files to extent trees, and to rebuild all extent files' extent trees. After conversion, files larger than 12 blocks should be defragmented to eliminate empty holes where a block lives. The extent tree constructor is pretty dumb -- it creates a list of leaf extents (adjacent extents are collapsed), marks all indirect blocks / ETB blocks free, installs a new extent tree root in the inode, then loads the leaf extents into the tree. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> |
||
---|---|---|
.. | ||
expect.1 | ||
expect.2 | ||
image.gz | ||
name |