[CRIU] [PATCH] mnt: add support for external shared mounts
Tycho Andersen
tycho.andersen at canonical.com
Mon Apr 6 07:48:29 PDT 2015
On Mon, Apr 06, 2015 at 11:26:41AM +0300, Pavel Emelyanov wrote:
> On 04/03/2015 07:20 PM, Tycho Andersen wrote:
> > Hi Andrey,
> >
> > On Fri, Apr 03, 2015 at 07:00:43PM +0300, Andrew Vagin wrote:
> >> On Thu, Apr 02, 2015 at 08:22:33PM +0000, Tycho Andersen wrote:
> >>> Add support for external shared mounts via the --enable-external-masters flag.
> >>> This flag assumes that the mount is visible to criu via /proc/self/mountinfo
> >>> and that it will be present at the same location on restore. No attempt to dump
> >>> or restore the content is made; the external master is bind mounted into the
> >>> mount ns and whatever is there is what the container sees.
> >>
> >> I need time to think about the idea. At the first glance it should work.
> >>
> >> But we (I and Pavel) are not sure that we understand what you do:).
> >>
> >> Could you show /proc/PID/mountinfo for a container? Why can you not use
> >> external mounts?
> >
> > Because criu dies with "couldn't find sharing" before the external
> > mount map is consulted. I could use ext-mount-map, but we'd still need
> > some patch to skip this check, and since we can resolve these
> > automatically anyway it seems like we should just do that instead.
>
> Ouch, so the slavery is set up for external mount points? I've missed that, sorry :(
> But taking into account my new insight :) doesn't the patch falls logically into
> two pieces -- the first is auto-assignments for ext-mount-map-s and the second --
> enabling for slave external bind mounts?
I guess it depends on how you want the implementation to work.
Currently it doesn't use the ext-mount-map piece, although I think it
could. I think we'd still need an extra flag in the protobufs to
indicate that the mount was an external sharing and would not be
provided by the user from the CLI on restore, so I'm not sure using
ext-mount-map really buys us much, but I can make those changes if you
want.
In any case, I have the set with the changes you and Andrey suggested
prepared, I will send that a long shortly.
Tycho
> -- Pavel
>
More information about the CRIU
mailing list