Lines Matching full:a
23 A process wants to clone its own namespace, but still wants to access the CD
36 a. shared mount
42 2a) A shared mount can be replicated to as many mountpoints and all the
47 Let's say /mnt has a mount that is shared::
65 a b c
68 a b c
70 Now let's say we mount a device at /tmp/a::
72 # mount /dev/sd0 /tmp/a
74 #ls /tmp/a
77 #ls /mnt/a
82 And the same is true even when /dev/sd0 is mounted on /mnt/a. The
83 contents will be visible under /tmp/a too.
86 2b) A slave mount is like a shared mount except that mount and umount events
89 All slave mounts have a master mount which is a shared.
93 Let's say /mnt has a mount which is shared.
99 the new mount at /tmp becomes a shared mount and it is a replica of
102 Now let's make the mount at /tmp; a slave of /mnt
105 let's mount /dev/sd0 on /mnt/a
106 # mount /dev/sd0 /mnt/a
108 #ls /mnt/a
111 #ls /tmp/a
129 2c) A private mount does not forward or receive propagation.
134 2d) A unbindable mount is a unbindable private mount
136 let's say we have a mount at /mnt and we make it unbindable::
146 Binding a unbindable mount is a invalid operation.
163 A) A process wants to clone its own namespace, but still wants to
173 Now any process that clones off a new namespace will have a
174 mount at /cdrom which is a replica of the same mount in the
177 So when a CD is inserted and mounted at /cdrom that mount gets
181 B) A process wants its mounts invisible to any other process, but
191 A new process can clone off a new namespace. And mark some part
207 The above semantics allows a way to share mounts across
210 associate/disassociate a namespace with userid, then each user
229 and if /usr has a versioning filesystem mounted, then that
233 A user can request v3 version of the file /usr/fs/namespace.c
247 5a) Mount states
249 A given mount can be in one of the following states
257 A 'propagation event' is defined as event generated on a vfsmount
260 A 'peer group' is defined as a group of vfsmounts that propagate
265 A 'shared mount' is defined as a vfsmount that belongs to a
281 A 'slave mount' is defined as a vfsmount that receives
284 A slave mount as the name implies has a master mount from which
286 the slave mount to the master. Only a shared mount can be made
287 a slave by executing the following command::
291 A shared mount that is made as a slave is no more shared unless
296 A vfsmount can be both shared as well as slave. This state
297 indicates that the mount is a slave of some vfsmount, and
303 peer group, and this peer-group is a slave of some other
306 Only a slave vfsmount can be made as 'shared and slave' by
311 or by moving the slave vfsmount under a shared vfsmount.
315 A 'private mount' is defined as vfsmount that does not
320 A 'unbindable mount' is defined as vfsmount that does not
327 The state diagram below explains the state transition of a mount,
351 ** slaving a non-shared mount has no effect on the mount.
354 the state of a mount depending on type of the destination mount. Its
361 mount --bind A/a B/b
363 where 'A' is the source mount, 'a' is the dentry in the mount 'A', 'B'
366 The outcome depends on the type of mount of 'A' and 'B'. The table
372 |source(A)->| shared | private | slave | unbindable |
384 1. 'A' is a shared mount and 'B' is a shared mount. A new mount 'C'
385 which is clone of 'A', is created. Its root dentry is 'a' . 'C' is
388 propagates to. A new propagation tree containing 'C1',..,'Cn' is
391 of 'A'.
393 2. 'A' is a private mount and 'B' is a shared mount. A new mount 'C'
394 which is clone of 'A', is created. Its root dentry is 'a'. 'C' is
397 propagates to. A new propagation tree is set containing all new mounts
401 3. 'A' is a slave mount of mount 'Z' and 'B' is a shared mount. A new
402 mount 'C' which is clone of 'A', is created. Its root dentry is 'a' .
405 'B' propagates to. A new propagation tree containing the new mounts
411 4. 'A' is a unbindable mount and 'B' is a shared mount. This is a
414 5. 'A' is a private mount and 'B' is a non-shared(private or slave or
415 unbindable) mount. A new mount 'C' which is clone of 'A', is created.
416 Its root dentry is 'a'. 'C' is mounted on mount 'B' at dentry 'b'.
418 6. 'A' is a shared mount and 'B' is a non-shared mount. A new mount 'C'
419 which is a clone of 'A' is created. Its root dentry is 'a'. 'C' is
420 mounted on mount 'B' at dentry 'b'. 'C' is made a member of the
421 peer-group of 'A'.
423 7. 'A' is a slave mount of mount 'Z' and 'B' is a non-shared mount. A
424 new mount 'C' which is a clone of 'A' is created. Its root dentry is
425 'a'. 'C' is mounted on mount 'B' at dentry 'b'. Also 'C' is set as a
426 slave mount of 'Z'. In other words 'A' and 'C' are both slave mounts of
427 'Z'. All mount/unmount events on 'Z' propagates to 'A' and 'C'. But
428 mount/unmount on 'A' do not propagate anywhere else. Similarly
431 8. 'A' is a unbindable mount and 'B' is a non-shared mount. This is a
432 invalid operation. A unbindable mount cannot be bind mounted.
448 A
455 of a type other than unbindable.
463 A'
475 mount --move A B/b
477 where 'A' is the source mount, 'B' is the destination mount and 'b' is
480 The outcome depends on the type of the mount of 'A' and 'B'. The table
481 below is a quick reference::
486 | source(A)->| shared | private | slave | unbindable |
496 .. Note:: moving a mount residing under a shared mount is invalid.
500 1. 'A' is a shared mount and 'B' is a shared mount. The mount 'A' is
503 propagation from mount 'B'. A new propagation tree is created in the
507 of 'A'.
509 2. 'A' is a private mount and 'B' is a shared mount. The mount 'A' is
512 propagation from mount 'B'. The mount 'A' becomes a shared mount and a
517 3. 'A' is a slave mount of mount 'Z' and 'B' is a shared mount. The
518 mount 'A' is mounted on mount 'B' at dentry 'b'. Also new mounts 'A1',
520 receive propagation from mount 'B'. A new propagation tree is created
524 'A'. Mount 'A' continues to be the slave mount of 'Z' but it also
527 4. 'A' is a unbindable mount and 'B' is a shared mount. The operation
530 propagation from 'B'. And since the mount 'A' is unbindable, cloning
533 5. 'A' is a private mount and 'B' is a non-shared(private or slave or
534 unbindable) mount. The mount 'A' is mounted on mount 'B' at dentry 'b'.
536 6. 'A' is a shared mount and 'B' is a non-shared mount. The mount 'A'
537 is mounted on mount 'B' at dentry 'b'. Mount 'A' continues to be a
540 7. 'A' is a slave mount of mount 'Z' and 'B' is a non-shared mount.
541 The mount 'A' is mounted on mount 'B' at dentry 'b'. Mount 'A'
542 continues to be a slave mount of mount 'Z'.
544 8. 'A' is a unbindable mount and 'B' is a non-shared mount. The mount
545 'A' is mounted on mount 'B' at dentry 'b'. Mount 'A' continues to be a
558 that the source mount is always a private mount.
565 umount A
567 where 'A' is a mount mounted on mount 'B' at dentry 'b'.
597 A cloned namespace contains all the mounts as that of the parent
600 Let's say 'A' and 'B' are the corresponding mounts in the parent and the
603 If 'A' is shared, then 'B' is also shared and 'A' and 'B' propagate to
606 If 'A' is a slave mount of 'Z', then 'B' is also the slave mount of
609 If 'A' is a private mount, then 'B' is a private mount too.
611 If 'A' is unbindable mount, then 'B' is a unbindable mount too.
616 A. What is the result of the following command sequence?
655 its root dentry is 1. Let's call this mount 'A'
656 And then we have a second mount at /tmp1 with root
658 Next we have a third mount at /mnt with root dentry
661 'B' is the slave of 'A' and 'C' is a slave of 'B'
662 A -> B -> C
668 The mount is attempted on 'A'
684 exportfs is a heavyweight way of accomplishing part of what
685 shared subtree can do. I cannot imagine a way to implement the
693 if one rbind mounts a tree within the same subtree 'n' times
773 One could use a series of umount at each step to prune
774 out the unneeded mounts. But there is a better solution.
845 8A) Datastructure
872 the vfsmount. MNT_SHARE indicates that the vfsmount is a shared
876 All the shared vfsmounts in a peer group form a cyclic list through
879 All vfsmounts with the same ->mnt_master form on a cyclic list anchored
883 of master peer group. To find all immediate slaves of a peer group
885 Conceptually it's just a single set - distribution among the
889 All vfsmounts in a peer group have the same ->mnt_master. If it is
890 non-NULL, they form a contiguous (ordered) segment of slave list.
892 A example propagation tree looks as shown in the figure below.
893 [ NOTE: Though it looks like a forest, if we consider all the shared
894 mounts as a conceptual entity called 'pnode', it becomes a tree]::
897 A <--> B <--> C <---> D
905 In the above figure A,B,C and D all are shared and propagate to each
906 other. 'A' has got 3 slave mounts 'E' 'F' and 'G' 'C' has got 2 slave
911 A's ->mnt_share links with the ->mnt_share of 'B' 'C' and 'D'
913 A's ->mnt_slave_list links with ->mnt_slave of 'E', 'K', 'F' and 'G'
917 'E', 'K', 'F', 'G' have their ->mnt_master point to struct vfsmount of 'A'
941 The former modifies a vfsmount that has not been visible in any shared
961 a) Create the necessary number of mount trees to
966 c) Link all the new mounts to form a propagation tree that