xfsprogs: sb_meta_uuid fixes
cover xfsprogs: sb_meta_uuid fixes
HI folks,
THis is the userspace side fixes that I've needed to make to get xfstests to pass without regressions with a modified sb_meta_uuid. Same circumstances as the kernel side patches I just sent....
Cheers,
Dave.
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
PATCH 1/2 repair: use sb_meta_uuid for checking of metadata headers
From: Dave Chinner <[email protected]>
Now that we can change the uuid on v5 filesystems, we always need to verify the metadata uuid against sb_meta_uuid, not sb_uuid. This fixes quite a few xfstests failures when UUIDs are changed before executing tests.
--- repair/phase6.c | 2 +- repair/scan.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
repair/phase6.c +1 -1
@@ -1960,7 +1960,7 @@ _("expected block %" PRIu64 ", got %llu, directory inode %" PRIu64 "\n"),return 1 ; }/* verify uuid */ -if (platform_uuid_compare (uuid, &mp->m_sb.sb_uuid) !=0 ) { +if (platform_uuid_compare (uuid, &mp->m_sb.sb_meta_uuid) !=0 ) {do_warn (_ ("wrong FS UUID, directory inode %" PRIu64" block %" PRIu64"\n" ), ino, bp->b_bn);
repair/scan.c +1 -1
@@ -237,7 +237,7 @@ _("expected block %" PRIu64 ", got %llu, bmbt block %" PRIu64 "\n"), }/* verify uuid */ if (platform_uuid_compare (&block->bb_u.l.bb_uuid, - &mp->m_sb.sb_uuid) !=0 ) { + &mp->m_sb.sb_meta_uuid) !=0 ) {do_warn (_ ("wrong FS UUID, bmbt block %" PRIu64"\n" ), bno);
Signature · 6 lines
2.1.4 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 1/2] repair: use sb_meta_uuid for checking of metadata headers
Quoted 8 lines · Dave Chinner
From: Dave Chinner <[email protected]>
Now that we can change the uuid on v5 filesystems, we always need to verify the metadata uuid against
sb_meta_uuid, notsb_uuid. This fixes quite a few xfstests failures when UUIDs are changed before executing tests.Signed-off-by Dave Chinner <[email protected]>
I have no plausible excuse for this one... ;)
Quoted 24 lines
--- repair/phase6.c | 2 +- repair/scan.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)repair/phase6.c +1
-1@@ -1960,7 +1960,7 @@ _("expected block %" PRIu64 ", got %llu, directory inode %" PRIu64 "\n"),return 1 ; }/* verify uuid */ -if (platform_uuid_compare (uuid, &mp->m_sb.sb_uuid) !=0 ) { +if (platform_uuid_compare (uuid, &mp->m_sb.sb_meta_uuid) !=0 ) {do_warn (_ ("wrong FS UUID, directory inode %" PRIu64" block %" PRIu64"\n" ), ino, bp->b_bn);repair/scan.c +0
-0
repair/scan.c _("expected block %" PRIu64 ", got %llu, bmbt block %" PRIu64 "\n"), · line 243
Quoted 8 lines
repair/scan.c +1
-1@@ -237,7 +237,7 @@ _("expected block %" PRIu64 ", got %llu, bmbt block %" PRIu64 "\n"), }/* verify uuid */ if (platform_uuid_compare (&block->bb_u.l.bb_uuid, - &mp->m_sb.sb_uuid) !=0 ) { + &mp->m_sb.sb_meta_uuid) !=0 ) {do_warn (_ ("wrong FS UUID, bmbt block %" PRIu64"\n" ), bno);
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
PATCH 2/2 libxfs: fix uuid check durign inode allocation
In reply to Dave ChinnerFrom: Dave Chinner <[email protected]>
Needs to check sb_meta_uuid now that we the sb_uuid can change on v5 filesystems.
--- libxfs/util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
libxfs/util.c +1 -1
@@ -262,7 +262,7 @@ libxfs_ialloc(if (ip->i_d.di_version ==3 ) {ASSERT (ip->i_d.di_ino == ino); -ASSERT (uuid_equal (&ip->i_d.di_uuid, &mp->m_sb.sb_uuid)); +ASSERT (uuid_equal (&ip->i_d.di_uuid, &mp->m_sb.sb_meta_uuid)); ip->i_d.di_crc =0 ; ip->i_d.di_changecount =1 ; ip->i_d.di_lsn =0 ;
Signature · 6 lines
2.1.4 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 2/2] libxfs: fix uuid check durign inode allocation
Quoted 6 lines · Dave Chinner
From: Dave Chinner <[email protected]>
Needs to check
sb_meta_uuidnow that we thesb_uuidcan change on v5 filesystems.Signed-off-by Dave Chinner <[email protected]>
ASSERTs are off in libxfs anyway right? Still:
Quoted 10 lines
--- libxfs/util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)libxfs/util.c +0
-0
libxfs/util.c libxfs_ialloc( · line 268
Quoted 8 lines
libxfs/util.c +1
-1@@ -262,7 +262,7 @@ libxfs_ialloc(if (ip->i_d.di_version ==3 ) {ASSERT (ip->i_d.di_ino == ino); -ASSERT (uuid_equal (&ip->i_d.di_uuid, &mp->m_sb.sb_uuid)); +ASSERT (uuid_equal (&ip->i_d.di_uuid, &mp->m_sb.sb_meta_uuid)); ip->i_d.di_crc =0 ; ip->i_d.di_changecount =1 ; ip->i_d.di_lsn =0 ;
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs