[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts
From: |
Miklos Szeredi |
Subject: |
Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts |
Date: |
Wed, 29 Apr 2020 10:52:46 +0200 |
On Wed, Apr 29, 2020 at 10:31 AM Max Reitz <address@hidden> wrote:
>
> On 28.04.20 21:15, Dr. David Alan Gilbert wrote:
> > So are you saying we need a:
> > if (mount(NULL, "/", NULL, MS_REC | MS_SHARED, NULL) < 0) {
> >
> > and can this go straight after (1) ?
>
> Isn’t MS_SHARED and MS_SLAVE mutually exclusive, that is, both are just
> different propagation types? So shouldn’t putting this after (1) be
> effectively the same as replacing (1)?
No, think of it more like a set of groups (mounts in a group have the
same "shared:$ID" tag in /proc/self/mountinfo) and these groups being
arranged into a tree, where child groups get propagation from the
parent group (mounts have a "master:$PARENT_ID" tag), but not the
other way round.
So if a mount is part of a shared group and this group is also the
child of another shared group, then it will have both a "shared:$ID"
and a "master:$PARENT_ID" tag in /proc/self/mountinfo.
For the gory details see Documentation/filesystems/sharedsubtree.txt
Thanks,
Miklos
- Re: [PATCH] virtiofsd: Show submounts, (continued)
- Re: [PATCH] virtiofsd: Show submounts, Daniel P . Berrangé, 2020/04/28
- Re: [PATCH] virtiofsd: Show submounts, Stefan Hajnoczi, 2020/04/28
- Re: [PATCH] virtiofsd: Show submounts, Daniel P . Berrangé, 2020/04/28
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts, Miklos Szeredi, 2020/04/28
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts, Dr. David Alan Gilbert, 2020/04/28
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts, Miklos Szeredi, 2020/04/29
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts, Miklos Szeredi, 2020/04/29
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts, Vivek Goyal, 2020/04/29
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts, Vivek Goyal, 2020/04/29
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts, Max Reitz, 2020/04/29
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts,
Miklos Szeredi <=
- Re: [Virtio-fs] [PATCH] virtiofsd: Show submounts, Max Reitz, 2020/04/29
Re: [PATCH] virtiofsd: Show submounts, Dr. David Alan Gilbert, 2020/04/29
- Re: [PATCH] virtiofsd: Show submounts, Vivek Goyal, 2020/04/29
- Re: [PATCH] virtiofsd: Show submounts, Max Reitz, 2020/04/30
- Re: [PATCH] virtiofsd: Show submounts, Dr. David Alan Gilbert, 2020/04/30
- Re: [PATCH] virtiofsd: Show submounts, Max Reitz, 2020/04/30
- Re: [PATCH] virtiofsd: Show submounts, Max Reitz, 2020/04/30
Re: [PATCH] virtiofsd: Show submounts, Vivek Goyal, 2020/04/30
Re: [PATCH] virtiofsd: Show submounts, Dr. David Alan Gilbert, 2020/04/30
Re: [PATCH] virtiofsd: Show submounts, Vivek Goyal, 2020/04/30