]> git.ipfire.org Git - thirdparty/e2fsprogs.git/commit
resize2fs: rewrite extent/dir/ea block checksums when migrating
authorDarrick J. Wong <darrick.wong@oracle.com>
Fri, 13 Dec 2013 04:34:55 +0000 (23:34 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Fri, 13 Dec 2013 04:34:58 +0000 (23:34 -0500)
commitfb47b94fffc780807531bd99b1cd69d8083334be
tree0c497fdfecc50dc68943f8c172b73a5e72e2c307
parent22cde0096db5f6dbff5bbdcc6d0919c35186fee5
resize2fs: rewrite extent/dir/ea block checksums when migrating

With the advent of metadata_csum, we now tie extent and directory
blocks to the associated inode number (and generation).  Therefore, we
must be careful when remapping inodes.  At that point in the resize
process, all the blocks that are going away have been duplicated
elsewhere in the FS (albeit with checksums based on the old inode
numbers).  If we're moving the inode, then do that and remember that
new inode number.  Now we can update the block mappings for each inode
with the final inode number, and schedule directory blocks for mass
inode relocation.  We also have to recalculate the EA block checksum.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
resize/resize2fs.c