Newsgroups: comp.os.linux.setup
> I really like the way my machine works and I have no problem with what fsck >does to it. But I'm an OpenGL developper and I always program with my video >card memory unprotected (3dfx). Sometimes, it crashes real hard. [verse]
Well … if it crashed a file system check may not be such a bad idea ? A JFS is helpful for sure, but a JFS is not going to prevent any loss of real data.
Still and depending on how you're using your system, of course you can skip the fsck. I've a self built system, so your /etc/bcheckrc is going to look different or reside in a different path, but an extract …
echo "*** RUNNING FSCK - PLEASE WAIT ***"
FSSTATUS=0
while read FSDEV FSMOUNT FSTYPE FSFLAGS FSDUMPFREQ FSFSCKPASS
do
if [ $FSTYPE = ext2 -a $FSFSCKPASS -ne 0 ]
then
if [ $FSMOUNT = "/" ]
then
FSROOT=$FSDEV
fi
/sbin/e2fsck $FSFORCEFSCK -p $FSDEV; FSSTATUS=$(( FSSTATUS | $? ))
fi
done < /etc/fstab
if [ $FSSTATUS -ge 2 ]
then
echo "*** FSCK EXITED WITH $FSSTATUS - STARTING MAINTAINCE SHELL ***"
/sbin/sulogin /dev/console
fi
... say e2fsck is run via some script. Means you can disable a fsck
easily. E.g. add something like ...
if [ ! -f /nofsck ]
then
fi.. Question is when to create /nofsck though … you could boot into different runlevels, say 2 for "normal" operation and 4 for development work, perhaps mounting some file systems ro and so on.
You could even disable the "standard" fsck completely, run a cronjob which creates a tag file /dofsck once a week and only check your filesystems if this file exists, removing it afterwards.
>I will then have to run fsck manually some times, or I would put it in my cron >deamon weekly...
You had better not run a e2fsck on a busy system. Mind a life system keeps changing the file systems information and a fs should be mounted ro before checking it.
In short since the file system check is not a kernel thingy you're pretty flexible.
Juergen
>> 2001.05.28 Mon 14:19:36