Дайте пожалуйста ссылку на доку, где популярно описаны флаги MS_SLAVE, MS_PRIVATE, MS_SHARE для syscall sys_mount
В манах ни чего нет, гугль тоже на даёт оптимисза. Это содержание я не могу осознатьDocumentation\sharedsubtree.txt:
2a) A shared mount can be replicated to as many mountpoints and all the
replicas continue to be exactly same.
Here is an example:
Lets say /mnt has a mount that is shared.
mount --make-shared /mnt
note: mount command does not yet support the --make-shared flag.
I have included a small C program which does the same by executing
'smount /mnt shared'
#mount --bind /mnt /tmp
The above command replicates the mount at /mnt to the mountpoint /tmp
and the contents of both the mounts remain identical.
#ls /mnt
a b c
#ls /tmp
a b c
Now lets say we mount a device at /tmp/a
#mount /dev/sd0 /tmp/a
#ls /tmp/a
t1 t2 t2
#ls /mnt/a
t1 t2 t2
Note that the mount has propagated to the mount at /mnt as well.
And the same is true even when /dev/sd0 is mounted on /mnt/a. The
contents will be visible under /tmp/a too.
Пясал аффтору Ram Pai linuxram@us.ibm.com, аффтар молчит как рыба