mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* mount --bind and /proc/mounts
@ 2007-01-02 13:55 Mark Hlawatschek
  0 siblings, 0 replies; only message in thread
From: Mark Hlawatschek @ 2007-01-02 13:55 UTC (permalink / raw)
  To: linux-kernel

Hi,

I'm using a shared root environment and therefore linked /etc/mtab 
to /proc/mounts. In addition I'm using --bind mount to make administration 
easier.

Now I found the following behaviour:
# mount -a 
is mounting all filesystems with bind options in the fstab 
everytime the command "mount -a " is executed. 

That works fine using an /etc/mtab file, but fails for --bind mounts 
using /etc/mtab linked to /proc/mounts.

I think this is because /etc/mtab has information about the source directory 
and /proc/mounts shows the device, hosting the filesystem.

e.g.
# mount --bind /tmp/bmount/ /mnt/bmount/
# cat /etc/mtab
(...) /tmp/bmount /mnt/bmount none rw,bind 0 0
# cat /proc/mounts
(...) /dev/root /mnt/bmount ext3 rw,data=ordered 0 0

Is there a solution for this ?
 
Thanks,

Mark





^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-01-02 14:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-02 13:55 mount --bind and /proc/mounts Mark Hlawatschek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®