United States (change)
Shortcuts: Downloads Fedora Red Hat Network
Account Links: Cart Your Account Logout
On an ext3 filesystem, fsck seems to loop forever, as shown int he following example:
e2fsck -y /dev/md0 e2fsck 1.37 (21-Mar-2005) Pass 1: Checking inodes, blocks, and sizes Inode 8 has illegal block(s). Clear? yes Illegal block #2371 (3939553560) in inode 8. CLEARED. Illegal block #2372 (2534662274) in inode 8. CLEARED. Illegal block #2373 (860109200) in inode 8. CLEARED. Illegal block #2374 (3289467369) in inode 8. CLEARED. Illegal block #2375 (3883044785) in inode 8. CLEARED. Illegal block #2376 (819724782) in inode 8. CLEARED. Illegal block #2377 (2957378758) in inode 8. CLEARED. Illegal block #2378 (1131441392) in inode 8. CLEARED. Illegal block #2379 (1473257247) in inode 8. CLEARED. Illegal block #2380 (2359314433) in inode 8. CLEARED. Illegal block #2381 (448867375) in inode 8. CLEARED. Too many illegal blocks in inode 8. Clear inode ? yes Restarting e2fsck from the beginning... Pass 1: Checking inodes, blocks, and sizes Inode 8 has illegal block(s). Clear ?
In this case, inode 8 is a journal inode. Removing the journal from the filesystem will allow fsck to run without the infinate loop. After fsck is run, the journal will be re-added to the filesystem.
Begin by removing the journal from the filesystem:
debugfs -w -R "feature ^has_journal,^needs_recovery" filesystem
Rerun fsck on the filesystem:
e2fsck -y filesystem
Add the journal back to the filesystem:
tune2fs -j filesystem