]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit - libxfs/init.c
xfs_repair: check filesystem geometry before allowing upgrades
authorDarrick J. Wong <djwong@kernel.org>
Fri, 5 Aug 2022 02:54:25 +0000 (21:54 -0500)
committerEric Sandeen <sandeen@sandeen.net>
Fri, 5 Aug 2022 02:54:25 +0000 (21:54 -0500)
commit7aeffc8708063dc48b3a6b7b596e3a14b775c769
treea91812f95dbd5e3a53bf6be08e1a9e24bf9b18ee
parentdb5b866537e78669f7b84590345b0c37f841f701
xfs_repair: check filesystem geometry before allowing upgrades

Currently, the two V5 feature upgrades permitted by xfs_repair do not
affect filesystem space usage, so we haven't needed to verify the
geometry.

However, this will change once we start to allow the sysadmin to add the
large extent count feature to existing filesystems.  Add all the
infrastructure we need to ensure that the log will still be large
enough, and the root inode will still be where we expect it to be after
the upgrade.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Chandan Babu R <chandan.babu@oracle.com>
[david: Recompute transaction reservation values; Exit with error if upgrade fails]
Signed-off-by: Dave Chinner <david@fromorbit.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
include/xfs_mount.h
libxfs/init.c
libxfs/libxfs_api_defs.h
repair/phase2.c