mount weirdness



Does mount ignore the entry for / in /etc/fstab, leaving whatever the
kernel was booted with as /, but when you run `mount' tell you what's in
fstab rather than what's really mounted?

I just had a bit of an adventure after upgrading the kernel on my HTPC,
which runs Debian unstable. It used to have / on /dev/hda5 but I moved
it to /dev/hda1 at some point. However, I must have forgotten to update
fstab because it was saying hda5 was root. Everything appeared OK,
`mount' was telling me hda5 was root, it had survived a number of
reboots, but then I got a mysterious error from grub. Playing with
System Rescue CD showed hda1 had the expected contents of / while hda5
was empty!

So I mounted hda1, amended its /boot/grub/menu.lst and /etc/fstab and
reran grub-install, which successfully made the system bootable again.
But when I checked /etc/fstab it said / was hda5 again! When I corrected
it and rebooted again, this time it stayed corrected as hda1.

--
TH * http://www.realh.co.uk
.



Relevant Pages

  • Re: mount weirdness
    ... Running mount on its own should read the contents of /etc/mtab. ... fstab because it was saying hda5 was root. ... System Rescue CD showed hda1 had the expected contents of / while hda5 ...
    (uk.comp.os.linux)
  • [BUG]: Crash with CONFIG_FAIR_CGROUP_SCHED=y
    ... If we skip the 'mount' command, there is no crash. ... mounting just the cpu or just the ns subsystem does not ... Kernel 2.6.24-rc1 on an x86_64 ...
    (Linux-Kernel)
  • Re: usb-storage && iRIVER flash player problem
    ... > The device is seen, but there is no way to mount it, nor re-partition ... explain that the mountable vfat partition under linux is the ... > debugging enabled and not as modules, directly into the kernel. ... > nfs warning: ...
    (Linux-Kernel)
  • Re: Getting CDRW to work in Debian
    ... Note that these instructions match a tuned modular kernel such as ... method to install your network and sound drivers. ... Test your configuration using cdrecord -scanbus. ... Create mount points for these devices. ...
    (Debian-User)
  • Re: mount weirdness
    ... the first call to mount, just after boot ... the root partition, which contains /etc/fstab. ... grub and lilo load the kernel, but do no mounting of any kind (grub ... The kernel, once loaded, then mounts the root filesystem or loads code ...
    (uk.comp.os.linux)