From: "Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com>
To: Miklos Szeredi <mszeredi@redhat.com>
Cc: mtk.manpages@gmail.com, Ram Pai <linuxram@us.ibm.com>,
lkml <linux-kernel@vger.kernel.org>,
"Serge E. Hallyn" <serge@hallyn.com>,
Al Viro <viro@zeniv.linux.org.uk>
Subject: Re: Mount namespace "dominant peer group"?
Date: Tue, 24 May 2016 17:57:44 -0500 [thread overview]
Message-ID: <f6d3f4b6-a029-d2a4-d3f3-f1e75b48590e@gmail.com> (raw)
In-Reply-To: <CAOssrKfmDEP3T6qpiAT5m4Y1CfzRPfzUt6ST2rcS+j0qek+mzw@mail.gmail.com>
On 05/23/2016 02:55 AM, Miklos Szeredi wrote:
> C is slave of B is slave of A. If a process can see (i.e. has under
> its root) A and C but not B then for C it will show
> master:B,propagate_from:A. This piece of information is shown because
> it can't see the immediate master (B) and so cannot determine the
> chain of propagation between the mounts it can see.
Thanks, Miklos!
> Concrete example:
Yep, that does it. Thanks for the walk through!
One piece missing below though, in case anyone else tries to walk
through.
> # mount --bind / /mnt
> # mount --bind /proc /mnt/proc
> # mount --make-private /mnt
> # mount --make-shared /mnt
> # mkdir /tmp/etc
> # mount --bind /mnt/etc /tmp/etc
> # mount --make-slave /tmp/etc
> # mount --make-shared /tmp/etc
# mkdir /mnt/tmp/etc
> # mount --bind /tmp/etc /mnt/tmp/etc
> # mount --make-slave /mnt/tmp/etc
> # cat /proc/self/mountinfo | grep /tmp/etc
> 164 40 253:1 /etc /tmp/etc rw,relatime shared:100 master:97 - ...
> # chroot /mnt
> # cat /proc/self/mountinfo
> 129 62 253:1 / / rw,relatime shared:97 - ...
> 168 129 253:1 /etc /tmp/etc rw,relatime master:100 propagate_from:97 - ...
Cheers,
Michael
--
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/
prev parent reply other threads:[~2016-05-24 22:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-20 21:24 Michael Kerrisk (man-pages)
2016-05-20 23:15 ` Ram Pai
2016-05-21 12:49 ` Michael Kerrisk (man-pages)
2016-05-23 7:55 ` Miklos Szeredi
2016-05-24 22:57 ` Michael Kerrisk (man-pages) [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=f6d3f4b6-a029-d2a4-d3f3-f1e75b48590e@gmail.com \
--to=mtk.manpages@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxram@us.ibm.com \
--cc=mszeredi@redhat.com \
--cc=serge@hallyn.com \
--cc=viro@zeniv.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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®