[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Switched from ext2 to ext3...no fsck needed after crash?



    "Willem-Jan" == Willem-Jan Meijer <meyer3@chello.nl> writes:

    Willem-Jan> Well, I read 2 reactions now and I see there's still
    Willem-Jan> an fsck needed, but I mean: in the ext2 fs you
    Willem-Jan> sometime have to do a forced check manually, so you
    Willem-Jan> have to type a command. Not that problem, but i'm
    Willem-Jan> talking about an headless, handless and footless box,
    Willem-Jan> wich is controlled remotely. When the system doesn't
    Willem-Jan> boot, I can't login.

    Willem-Jan> When there's a crash...do I still have to type a
    Willem-Jan> command? If yes --> is there a filesystem where I
    Willem-Jan> don't have to type a command?

Well, yes, there is such an FS: it's called ext2 :-)

The scenario you are describing has to do with the way the system
boots. See the script /etc/init.d/checkroot.sh and
/etc/init.d/checkfs.sh for details. 

Basically, they both source a file called /etc/default/rcS where you
can set an option via the variable FSCKFIX. If you set it to "yes"
then fsck is started with the '-y' flag. This tells e2fsck to assume
that any question should be answered as 'yes' and go ahead in a
non-interactive manner. On a headless system you could use this
setting to continue after most crash problems. If your disk is so
badly hosed that answering 'y' still will not correct the file system
you are still stuck with a prompt (see checkroot.sh for an explanation
why), but at this point you probably don't want your system to boot
anyway!

I have not actually had to use this feature in real life (my headless
systems with ext2 have not yet crashed on me in the last few years),
so you don't have to trust me on anything ;-)

Cheers!
Shyamal



Reply to: