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

Re: root fs type in fstab



Leen Besselink writes:
> Although I have very little experience with ext3 yet, what if you changed
> /etc/fstab before that first reboot ? then it should be alright, right ?
> 
> Because then it would see it's ext3 and mount it ext3 ??

Actually, when the root fs is mounted, it does not have access to /etc/fstab,
because that is on the root fs...  What happens is that all of the filesystems
compiled into the kernel are tried, until one says it mounted the root device
properly.  However, it is possible to have a different filesystem type in
/etc/fstab and you may never notice it, because /etc/mtab is simply copied
from /etc/fstab for the root filesystem.  The only way to be sure is by
checking /proc/mounts.  Luckily e2fsck (>= 1.19) can handle both ext2 and
ext3 so it doesn't matter which is in /etc/fstab.

Maybe for the root filesystem, fsck should check /proc/mounts before
/etc/fstab to ensure it is checking the correct filesystem type...

Cheers, Andreas
-- 
Andreas Dilger  \ "If a man ate a pound of pasta and a pound of antipasto,
                 \  would they cancel out, leaving him still hungry?"
http://www-mddsp.enel.ucalgary.ca/People/adilger/               -- Dogbert





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