[CRIU] [PATCH 3/4] mount: Handle deleted bindmounts

Cyrill Gorcunov gorcunov at gmail.com
Wed Aug 26 04:38:47 PDT 2015


On Wed, Aug 26, 2015 at 02:30:52PM +0300, Andrew Vagin wrote:
> On Mon, Aug 17, 2015 at 11:09:48PM +0300, Cyrill Gorcunov wrote:
> > @@ -1990,11 +1994,25 @@ static int do_bind_mount(struct mount_info *mi)
> >  		root = rpath;
> >  do_bind:
> >  		pr_info("\tBind %s to %s\n", root, mi->mountpoint);
> > -		if (mount(root, mi->mountpoint, NULL,
> > -					MS_BIND, NULL) < 0) {
> > +
> > +		if (unlikely(mi->deleted)) {
> > +			if (mkdir(root, 0700)) {
> 
> https://github.com/xemul/criu/issues/9
> In this issue a file was bind-mounted. Can we handle this case?

Not sure I follow. If the source has been deleted there is no
way to figure out if it was a file or directory, you mean this?
Or something else?


More information about the CRIU mailing list