Question about forcing fsck at boottime
crapsh at monkeybrains.net
Mon Mar 30 23:30:07 PDT 2009
manish jain wrote:
> I am migrating from Linux and am still learning the basics of FreeBSD.
> One thing that I would to carry over from my Linux days is to force an
> fsck on all filesystems at system startup. On Linux, this was simply a
> matter of editing /etc/rc.sysinit. Things seem a bit more complicated
> in the BSD world. Can somebody please point me in the right direction ?
Traditionally, fsck is invoked before the file systems are mounted and all
checks are done to completion at that time. If background checking is
available, fsck is invoked twice. It is first invoked at the
time, before the file systems are mounted, with the -F flag to do
ing on all the file systems that cannot do background checking.
Also, you can set this in /etc/rc.conf
if you want to automatically run 'fsck -y' ... handy for remote servers.
Oh, and if you use ZFS, there is no such thing as 'fsck'. That file
system never needs fsck. :) If you want less fsck headaches on a big
disk system, make the large partion (/home ?) ZFS.
More information about the freebsd-questions