> Quoting Eric W. Biederman (
ebiederm@xmission.com):
> > "Serge E. Hallyn" <serue@us.ibm.com> writes:
> > > so on the bright side I pulled this tree today and it compiled and
> > > passed ltp with no problems.
> > >
> > > But then I played around a bit and found I could do the following:
> > >
> > > (hmm, i'm trying to remember the exact order :)
> > >
> > > as root:
> > > mmount --bind -o user=500 /home/hallyn/etc/ /home/hallyn/etc/
> > > mount --bind /mnt /mnt
> > > mount --make-rshared /mnt
> > > mount --bind /dev /mnt/dev
> > >
> > > as hallyn:
> > > mmount --bind /mnt /home/hallyn/etc/mnt
> > > /usr/src/mmount-0.3/mmount --bind mnt/dev mnt/src
> >
> > You are using relative directory names here which makes it confusing.
> > I'm assuming you in /home/hallyn/etc ?
>
> Sorry, yeah.
>
> > > Now /mnt/src contained /dev.
> > >
> > > Is this what we want?
> >
> > I don't think so.
> >
> > I think the simplest answer is to not allow mounting of shared
> > subtrees controlled by a different user.
> >
> > Serge I think you are right downgrading the mount from shared to slave
> > looks like the sane thing to do if the mount owners match.
>
> I assume you mean "if the mount owners don't match"?
>
> Miklos, what do you think?