Messages in this thread | | | From | "Ulrich Windl" <> | Date | Mon, 12 Jul 2004 08:55:09 +0200 | Subject | Murphy hits (Kernel 2.6, ext2, "check=strict"): corrupted filesystem |
| |
Hello everybody,
I'd like to present a little story how to shredder your ext2 filesystem:
I was installing SuSE Linux 9.1 when the kernel froze rather late during installation. So I had to reset the PC. There is a minor bug in the forementioned distribution that prevents a filesystem check of the root filesystem after such a crash it seems. Anyway, the system booted without a fsck being run. I realized that and shut down (maybe it would have been better to hit the reset button immediately), but during the manual fsck, the system reported (among a lot of others) about 1700 inodes that share blocks. You can imagine what that means...
Why I'm writing this: If something can go wrong, eventually it will. For a true disaster you always need more than just one problem (1: Kernel freeze, 2: no fsck being run, 3: kernel happily mounts unclean filesystem for read-write).
In Kernel 2.2 there was a "check=strict" that caused some extra checks during mounting a filesystem. In 2.4 the option was ignored, and a warning was presented instead. In 2.6 it seems that "check=strict" prevents the filesystem from being mounted read-write (I ended up with an read-only root filesystem when having that option).
I'll have to spend a few more days to cleanup the mess in the root filesystem (which is everything except /home and /boot), but the lession to learn might be this: The kernel should not mount a unclean filesystem read-write. Maybe also if a filesystem code results in an attempt to access a partition outside its limits, the filesystem should trtigger a panic immediately instead of going on.
I think nobody really wants to read reports where Linux has shreddered a filesystem, do we?
Regards, Ulrich
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |