Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#28 too many illegal blocks while fsck

open
nobody
None
5
2012-11-28
2009-08-15
Andrey Gursky
No

fsck finds illegal block(s) in one inode
Clear? yes
Then it tells there are too many illegal blocks in inode and asks
Clear indoe? yes
Then it restarts and... asks at the same place about illegal blocks. It clears the next 11 and tells there are too many. And so on.

With debugfs I tried manually to clear this inode. It tells also there are invalid blocks, and these remain in inode. clri clears the indoe but after close and open the fs, the inode is again full with invalid blocks. The affected inode was owned by file I've deleted some hours before sata-controller decided to write another file at invalid place, what leaded to errors in filesystem.

My question would be, why I can neither with debugfs, nor with fsck solve the problem of freeing an inode with invalid blocks? In particulary,
1) Why fsck seems to clear the inode, but after restarting finds again the next 11 invalid blocks?
2) Why debugfs after ignores freei and clri on this inode after close and open the affected fs?
Could you help me to solve this problem?

Thanks in advance!

P.S. I've used the 1.41.3 and also the most recent version 1.41.8 of e2fsprogs.

Discussion

  • Andrey Gursky
    Andrey Gursky
    2009-08-15

    Just more info. I knew some files were written to the partition while this issue. So if I ls the directory with some of them, I receive:
    Stale NFS file handler
    And no date/time/rights for these files. But fsck didn't complain about inodes containing these files.

     
  • > But fsck didn't complain about inodes containing these files.

    I assume, fsck would fix it, if it could go on with checking. But as mentioned above, it stucks on pass1, because it should got the inode with too many invalid blocks cleared, but after restarting it is not so.

    By the way, after I played a little bit with these halfdead files (two of them): sif links_count, sif dtime, I figured out, that fsck also complains on them, their inodes have too many illegal blocks and it clears "successfully" the inode (after restart fsck is satisfied with these inodes in the pass1).

     
  • Andrey Gursky
    Andrey Gursky
    2009-08-16

    Sorry, I sent the last message, while I wasn't logged in.