Re: [PATCH] 00/13 e2fsprogs-1.39 extent checking improvements

Alexandre Ratchov <[email protected]> Mon, 21 Aug 2006 18:24:04 +0200
Newsgroups gmane.comp.file-systems.ext2.devel
Message-ID <[email protected]>
On Fri, Aug 04, 2006 at 03:30:01PM -0400, Jarod Wilson wrote:
> On Fri, 2006-08-04 at 13:15 -0500, Eric Sandeen wrote:
> > Jarod Wilson wrote:
> > 
> > > Eep, how far have you got? I spent a while working on it myself earlier 
> > > today...
> > 
> > I've got it pretty much done; I'll send it out Monday, probably as:
> > 
> > <original-sfnet-extents-patch>
> > <adilger-extent-fixes-on-top-of-that-patch>
> > <updated-sfnet-ext4-patches-which-follow>
> > 
> > Jarod has an rpm built with my patch stack now...
> 
> Well, an srpm, the rpm won't finish building yet due to failures in
> 'make check'. ;)
> 
> The binaries themselves build on x86_64, i386 and ppc, but all fail
> 'make check' in one form or another. I'm seeing i386 still fail with an
> "error 113" in tst_iscan and powerpc segfaulting on tst_badblocks. On
> x86_64, with the addition of 5 of the 6 bits from the earlier test
> output patch I threw out there, I'm down to 80 tests passing, 3 failing.
> Of course, I still don't know for sure that the patched up output is
> really correct, but the results are always the same (tested on multiple
> x86_64 systems).
> 
> $ grep failed | e2fsprogs-testoutput
> 
> f_bbfile: bad blocks in files: failed
> f_extents: extent-mapped files with errors: failed
> f_lotsbad: too many illegal blocks in inode: failed
> 80 tests succeeded      3 tests failed
> 
> According to Andreas, the f_lotsbad test is expected to fail right now,
> leaving two others that still need to be investigated. I had patched up
> the f_bbfile expected output previously, but its been altered again by
> the addition of Andreas' patches. No clue why f_extents is failing on me
> yet.
> 
> I'll post the srpm with Eric's final rendition of the patch merge on
> Monday too.
> 

hi,

some of the above errors are because of a bug in the "pblk" patch; here is
the fix. It's to be applied on top of the "pblk" patch; It fixes the following
tests: f_badtable, f_bbfile, f_illibitmap, f_overfsblks tests.

unfortunately there are still other bugs, i hope i'll find a fix soon.

cheers,

-- 
Alexandre

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642

_______________________________________________
Ext2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ext2-devel
pblk_fix (text/plain, 1.5 KB)
Index: e2fsprogs-1.39/e2fsck/pass1.c
===================================================================
--- e2fsprogs-1.39.orig/e2fsck/pass1.c	2006-08-21 19:01:03.000000000 +0200
+++ e2fsprogs-1.39/e2fsck/pass1.c	2006-08-21 19:07:43.000000000 +0200
@@ -2226,19 +2226,19 @@ static void handle_fs_bad_blocks(e2fsck_
 
 	for (i = 0; i < fs->group_desc_count; i++) {
 		if (ctx->invalid_block_bitmap_flag[i]) {
-			blk_t blk;
+			blk_t blk = fs->group_desc[i].bg_block_bitmap;
 			new_table_block(ctx, first_block, i, _("block bitmap"),
 					1, &blk);
 			fs->group_desc[i].bg_block_bitmap = blk;
 		}
 		if (ctx->invalid_inode_bitmap_flag[i]) {
-			blk_t blk;
+			blk_t blk = fs->group_desc[i].bg_inode_bitmap;
 			new_table_block(ctx, first_block, i, _("inode bitmap"),
 					1, &blk);
 			fs->group_desc[i].bg_inode_bitmap = blk;
 		}
 		if (ctx->invalid_inode_table_flag[i]) {
-			blk_t blk;
+			blk_t blk = fs->group_desc[i].bg_inode_table;
 			new_table_block(ctx, first_block, i, _("inode table"),
 					fs->inode_blocks_per_group, 
 					&blk);
Index: e2fsprogs-1.39/debugfs/icheck.c
===================================================================
--- e2fsprogs-1.39.orig/debugfs/icheck.c	2006-08-21 19:01:03.000000000 +0200
+++ e2fsprogs-1.39/debugfs/icheck.c	2006-08-21 19:02:05.000000000 +0200
@@ -112,7 +112,7 @@ void do_icheck(int argc, char **argv)
 		bw.inode = ino;
 
 		if (inode.i_file_acl) {
-			blk_t i_file_acl;
+			blk_t i_file_acl = inode.i_file_acl;
 			icheck_proc(current_fs, &i_file_acl, 0,
 				    0, 0, &bw);
 			inode.i_file_acl = i_file_acl;