lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Fri, 12 Aug 2011 11:44:41 +0800
From:	Robin Dong <hao.bigrat@...il.com>
To:	"Ted Ts'o" <tytso@....edu>
Cc:	linux-ext4@...r.kernel.org
Subject: Re: [PATCH 1/2 bigalloc] e2fsprogs: remove wrong EXT2FS_C2B in check_block_end

2011/8/11 Ted Ts'o <tytso@....edu>:
> On Thu, Aug 04, 2011 at 11:48:02AM +0800, Robin Dong wrote:
>> From: Robin Dong <sanbai@...bao.com>
>>
>> The argument "save_blocks_count" and the block bitmap has the unit of cluster,
>> so it don't need EXT2FS_C2B to convert argument "i".
>>
>> This patch is based on "next" branch of e2fsprogs.
>>
>> Signed-off-by: Robin Dong <sanbai@...bao.com>
>> Cc: Ted Ts'o <tytso@....edu>
>
> No, I don't think this is right.  Regardless of whether the unit of
> the block bitmap is cluster- or block- (only while mke2fs is running,
> and only initially) based, the argument to
> ext2fs_{test,mark,unmark}_block_bitmap is always in blocks.
>
> That's why the EXT2FS_C2B is necessary.
>
>                                        - Ted
>

Hi, Ted

Last week I did some wrecking-case to test e2fsck ("next" branch) and
find a error in it:

1. misc/mke2fs -m 0 -O
^has_journal,^resize_inode,^uninit_bg,bigalloc,extent,meta_bg,flex_bg
/dev/sda4
2. copy some file into /dev/sda4
3. set an inode's mode to zero
4. e2fsck -f /dev/sda4

it report something like:

e2fsck 1.42-WIP (02-Jul-2011)
Pass 1: Checking inodes, blocks, and sizes
Inode 314, i_blocks is 128, should be 0.  Fix<y>? yes

Pass 2: Checking directory structure
Inode 314 (/c/3) has invalid mode (00).
Clear<y>? yes

Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
Block bitmap differences:  -529632
Fix<y>? yes

Free blocks count wrong for group #1 (32267, counted=32268).
Fix<y>? yes

Free blocks count wrong (13838736, counted=13838752).
Fix<y>? yes

Illegal block number passed to ext2fs_test_block_bitmap #13874128 for
converted cluster bitmap
Padding at end of block bitmap is not set. Fix<y>? yes

Illegal block number passed to ext2fs_mark_block_bitmap #13874128 for
converted cluster bitmap
Illegal block number passed to ext2fs_mark_block_bitmap #13874144 for
converted cluster bitmap
Illegal block number passed to ext2fs_mark_block_bitmap #13874160 for
converted cluster bitmap
Illegal block number passed to ext2fs_mark_block_bitmap #13874176 for
converted cluster bitmap
Illegal block number passed to ext2fs_mark_block_bitmap #13874192 for
converted cluster bitmap
Illegal block number passed to ext2fs_mark_block_bitmap #13874208 for
converted cluster bitmap
Illegal block number passed to ext2fs_mark_block_bitmap #13874224 for
converted cluster bitmap
.......

my disk has just 13874128 4k-blocks, so the block number must have
some problems.
So I doubt at the check_block_end in pass5.c.
Could you please shed some light on it?


-- 
--
Best Regard
Robin Dong
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists