]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
xfs: clear BAD_SUMMARY if unmounting an unhealthy filesystem
authorDarrick J. Wong <darrick.wong@oracle.com>
Wed, 24 Jul 2019 19:53:56 +0000 (15:53 -0400)
committerEric Sandeen <sandeen@redhat.com>
Wed, 24 Jul 2019 19:53:56 +0000 (15:53 -0400)
Source kernel commit: 519841c207de9926418d2f39e162097088478781

If we know the filesystem metadata isn't healthy during unmount, we want
to encourage the administrator to run xfs_repair right away.  We can't
do this if BAD_SUMMARY will cause an unclean log unmount to force
summary recalculation, so turn it off if the fs is bad.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
libxfs/xfs_health.h

index 95053564a0d50ebee0b21abbc6a59800de0b9db7..0915d20975bee2ad2025eb4b0cabad822589582f 100644 (file)
@@ -118,6 +118,8 @@ void xfs_inode_mark_healthy(struct xfs_inode *ip, unsigned int mask);
 void xfs_inode_measure_sickness(struct xfs_inode *ip, unsigned int *sick,
                unsigned int *checked);
 
+void xfs_health_unmount(struct xfs_mount *mp);
+
 /* Now some helpers. */
 
 static inline bool