[Pkg-sysvinit-devel] Bug#338801: Revert?

Thomas Hood jdthood at yahoo.co.uk
Sun Jan 22 10:57:13 UTC 2006


I am thinking of reverting this change because it does not work well in a chroot
environment.  /proc/mounts read from within a chroot shows a list of mounts that
includes mounts outside the chroot and it shows them with paths that aren't
valid inside the chroot.

E.g.:

(standard root)$ cat /proc/mounts
rootfs / rootfs rw 0 0
none /sys sysfs rw 0 0
none /proc proc rw,nodiratime 0 0
udev /dev tmpfs rw 0 0
[...]
proc /mnt/hda6/proc proc rw,nodiratime 0 0
sysfs /mnt/hda6/sys sysfs rw 0 0
usbfs /mnt/hda6/proc/bus/usb usbfs rw 0 0
tmpfs /mnt/hda6/dev/shm tmpfs rw 0 0
devpts /mnt/hda6/dev/pts devpts rw 0 0
none /mnt/hda6/proc proc rw,nodiratime 0 0

(chroot)$ cat /proc/mounts
rootfs / rootfs rw 0 0                    <- mounts outside the chroot
none /sys sysfs rw 0 0
none /proc proc rw,nodiratime 0 0
udev /dev tmpfs rw 0 0
[...]
proc /proc proc rw,nodiratime 0 0
sysfs /sys sysfs rw 0 0
usbfs /proc/bus/usb usbfs rw 0 0
tmpfs /dev/shm tmpfs rw 0 0
devpts /dev/pts devpts rw 0 0
none /proc proc rw,nodiratime 0 0


I understand the argument that /etc/mtab sometimes contains less information than
/proc/mounts.  However AIUI sometimes it contains more.

The administrator has the option of symlinking /etc/mtab to /proc/mounts if using
the latter is preferred.
-- 
Thomas Hood




More information about the Pkg-sysvinit-devel mailing list