Mountfs and runlevels

Doug Reich dreich at
Sat Sep 4 23:02:30 PDT 2004

I recently had a great deal of trouble with my system and a corrupt
partition. When it came to mounting filesystems, my system would hang
and I received dma_expiry errors. The solution, for anyone who is
interested, was to run "e2fsck -c {partition}" which checks for, and
corrects, bad blocks on the filesystem.

The LFS runscripts attempt to mount all filesystems in
rcsysinit.d. This is a very bad idea, as I discovered. My problem was
with the partition on /usr, and my system would hang whenever I would
attempt to mount it. The entire purpose of runlevel 1 is to have a
bare-bones system on which the least can go wrong, and thus
the system can be diagnosed and fixed. Toward this end, only the root
filesystem should be mounted, and all other filesystems should be
mounted in higher runlevels. In addition, I also realize two other

1. there should be a statically linked editor on the root
filesystem so the user can edit files that need changing, and

2. the creation of a boot disk should be stressed more, should one
find their system completely unusable.

Clearly, the solution is to have "mountfs" only mount the root
filesystem and /proc and other things. Another file "mountother" or
something along those lines should run "mount -a" or whatever else
needs to be done.

I'd really like this changed so other people can have an easier time
solving problems when they can't make it to runlevel 3 or higher.


More information about the lfs-book mailing list