#193 Infinite? loop in e2fsck

open
e2fsck (61)
5
2012-11-28
2007-11-28
Jan Kara
No

If I create a filesystem with SPARSE_SUPER feature, fill it, remove the SPARSE_SUPER feature with tune2fs and then call e2fsck, it will loop in an infinite loop. Messages look like:

Group 6's block bitmap at 49153 conflicts with some other fs block.
Relocate<y>? yes

Group 6's inode bitmap at 49154 conflicts with some other fs block.
Relocate<y>? yes

Error allocating 1 contiguous block(s) in block group 2 for block bitmap: Could not allocate block in ext2 filesystem
Error allocating 1 contiguous block(s) in block group 2 for inode bitmap: Could not allocate block in ext2 filesystem
Error allocating 256 contiguous block(s) in block group 2 for inode table: Could not allocate block in ext2 filesystem
Error allocating 1 contiguous block(s) in block group 4 for block bitmap: Could not allocate block in ext2 filesystem
Error allocating 1 contiguous block(s) in block group 4 for inode bitmap: Could not allocate block in ext2 filesystem
Error allocating 256 contiguous block(s) in block group 4 for inode table: Could not allocate block in ext2 filesystem
Error allocating 1 contiguous block(s) in block group 6 for block bitmap: Could not allocate block in ext2 filesystem
Error allocating 1 contiguous block(s) in block group 6 for inode bitmap: Could not allocate block in ext2 filesystem
Error allocating 256 contiguous block(s) in block group 6 for inode table: Could not allocate block in ext2 filesystem
Restarting e2fsck from the beginning...
yy/tmp/image1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Group 2's inode table at 16387 conflicts with some other fs block.
Relocate<y>? yes

And the check starts from the beginning...

Discussion

  • Nobody/Anonymous

    Logged In: NO

    I am voting for this bug. I have the same problem with bothe verion 1.40.8 (binary form zenwalk) and 1.40.10 (compiled from source).
    fsck 1.40.8 (13-Mar-2008)
    /dev/sdb1 contains a file system with errors, check forced.
    Pass 1: Checking inodes, blocks, and sizes
    Group 7's inode table at 229381 conflicts with some other fs block.
    Relocate? yes

    Group 7's inode table at 229382 conflicts with some other fs block.
    Relocate? yes

    Group 7's inode table at 229383 conflicts with some other fs block.
    Relocate? yes

    Group 7's inode table at 229384 conflicts with some other fs block.
    Relocate? yes

    Group 7's inode table at 229385 conflicts with some other fs block.
    Relocate? yes

    ...

    Group 49's inode table at 1605890 conflicts with some other fs block.
    Relocate? yes

    Group 49's inode table at 1605891 conflicts with some other fs block.
    Relocate? yes

    Group 49's inode table at 1605892 conflicts with some other fs block.
    Relocate? yes

    Root inode is not a directory. Clear? yes

    /dev/sdb1: | | 0.4%
    /dev/sdb1: | / 0.9%
    /dev/sdb1: |= - 1.3%
    /dev/sdb1: |= \ 1.8%
    /dev/sdb1: |= | 2.2%
    /dev/sdb1: |= / 2.7%
    /dev/sdb1: |== - 3.1%
    /dev/sdb1: |== \ 3.6%
    /dev/sdb1: |== | 4.0%
    /dev/sdb1: |== / 4.5%
    /dev/sdb1: |=== - 4.9%
    /dev/sdb1: |=== \ 5.4%
    /dev/sdb1: |=== | 5.8%
    /dev/sdb1: |=== / 6.2%
    /dev/sdb1: |==== - 6.7%
    /dev/sdb1: |==== \ 7.1%
    /dev/sdb1: |==== | 7.6%
    /dev/sdb1: |==== / 8.0%
    /dev/sdb1: |===== - 8.5%
    /dev/sdb1: |===== \ 8.9%
    /dev/sdb1: |===== | 9.4%
    /dev/sdb1: |===== / 9.8%
    /dev/sdb1: |====== - 10.3%
    /dev/sdb1: |====== \ 10.7%
    /dev/sdb1: |====== | 11.1%
    /dev/sdb1: |====== / 11.6%
    /dev/sdb1: |======= - 12.0%
    /dev/sdb1: |======= \ 12.5%
    /dev/sdb1: |======= | 12.9%
    /dev/sdb1: |======= / 13.4%
    /dev/sdb1: |======== - 13.8%
    /dev/sdb1: |======== \ 15.2%
    /dev/sdb1: |========= | 16.5%
    /dev/sdb1: |========== / 17.8%
    /dev/sdb1: |=========== - 19.6%
    /dev/sdb1: |============ \ 21.0%
    /dev/sdb1: |============= | 22.7%
    /dev/sdb1: |============= / 24.1%
    /dev/sdb1: |============== - 25.9%
    /dev/sdb1: |=============== \ 27.6%
    /dev/sdb1: |================ | 29.4%
    /dev/sdb1: |================= / 30.3%
    /dev/sdb1: |================== - 32.1%
    /dev/sdb1: |=================== \ 33.9%
    /dev/sdb1: |=================== | 34.8%
    /dev/sdb1: |==================== / 36.6%
    /dev/sdb1: |===================== - 38.3%
    /dev/sdb1: |====================== \ 40.1%
    /dev/sdb1: |======================= | 41.5%
    /dev/sdb1: |======================== / 43.2%
    /dev/sdb1: |========================= - 44.6%
    /dev/sdb1: |========================== \ 46.4%
    /dev/sdb1: |=========================== | 47.7%
    /dev/sdb1: |=========================== / 49.0%
    /dev/sdb1: |============================ - 50.4%
    /dev/sdb1: |============================= \ 52.2%
    /dev/sdb1: |============================== | 53.5%
    /dev/sdb1: |=============================== / 54.8%
    /dev/sdb1: |=============================== - 56.2%
    /dev/sdb1: |================================ \ 58.0%
    /dev/sdb1: |================================= | 59.3%
    /dev/sdb1: |================================== / 60.6%
    /dev/sdb1: |=================================== - 62.4%
    /dev/sdb1: |==================================== \ 64.2%
    /dev/sdb1: |===================================== | 65.5%
    /dev/sdb1: |===================================== / 66.9%
    /dev/sdb1: |====================================== - 68.7%
    /dev/sdb1: |======================================= \ 70.0%
    
    Error allocating 256 contiguous block(s) in block group 7 for inode table: Could not allocate block in ext2 filesystem
    Error allocating 256 contiguous block(s) in block group 9 for inode table: Could not allocate block in ext2 filesystem
    Error allocating 256 contiguous block(s) in block group 25 for inode table: Could not allocate block in ext2 filesystem
    Error allocating 256 contiguous block(s) in block group 27 for inode table: Could not allocate block in ext2 filesystem
    Error allocating 256 contiguous block(s) in block group 49 for inode table: Could not allocate block in ext2 filesystem
    Restarting e2fsck from the beginning...
    /dev/sdb1 contains a file system with errors, check forced.
    Pass 1: Checking inodes, blocks, and sizes
    Group 7's inode table at 229381 conflicts with some other fs block.
    Relocate? yes

    Group 7's inode table at 229382 conflicts with some other fs block.
    Relocate? yes

    Group 7's inode table at 229383 conflicts with some other fs block.
    Relocate? yes

    ...etc

     
  • Theodore Ts'o

    Theodore Ts'o - 2008-07-10

    Logged In: YES
    user_id=628
    Originator: NO

    This problem should happen much less often with e2fsprogs 1.41, since it will detect the corrupted block group descriptors that lead to this state, and try to fix it by using the backup superblock.
    This isn't a complete and total solution, since a filesystem that is reached this state won't be fixable using e2fsck, but that's probably too much to hope for.