[lxc-users] LXC, criu and cgroups...

Tycho Andersen tycho.andersen at canonical.com
Mon Apr 6 15:00:31 UTC 2015


Hi Dirk,

On Sun, Apr 05, 2015 at 11:31:48AM +0200, Dirk Geschke wrote:
> Hi all,
> 
> I was just playing with lxd and tried the move command but it
> failed with 
> 
>    error: checkpoint failed
> 
> I think, this is not a problem of lxd but of criu with cgroups.
> 
> The running container is semi-unprivileged, I can start it without
> problems.

We currently cannot migrate unprivileged containers, so any container
you want to migrate needs to be a privileged container.

> But if I use cgmanager, then criu fails with:
> 
>    Error (mount.c:624): 94:./sys/fs/cgroup/cgmanager doesn't have a proper root mount

This should be fixed by a patch I posted to the mailing list a few
weeks ago (it finally got acked last Friday, and I think the plan is
to push it today, so you might re-try with the daily build tomorrow).

Once these are pushed, I will do a blog post on exactly the
configuration and versions of things needed to checkpoint and restore
containers with LXD.

Tycho

> If I do not use cgamager but mount /sys/fs/cgroup:
> 
>    mount -t cgroup cgroup /sys/fs/cgroup/
> 
> I get this error:
> 
>    Error (mount.c:624):
>    74:./sys/fs/cgroup/cpuset,cpu,cpuacct,blkio,memory,devices,freezer,net_cls,perf_event,net_prio,hugetlb,debug/lxc/wheezy2 doesn't have a proper root mount
> 
> This is with criu 1.5.1, with version 1.3.1 I get the same errors,
> but at least there are *.img files created (and deleted).
> 
> Has anyone an idea what is going wrong?
> 
> It is lxd-0.5, lxc-1.1.1 (the git repository says still 1.1.0?) and
> kernel 4.0-rc6 with criu-1.5.1. The kernel is adjusted to work with
> criu, except:
> 
>    # criu check
>    Warn  (cr-check.c:581): Dirty tracking is OFF. Memory snapshot will not work.
>    Looks good.
> 
> There is a kernel patch for this, but I did not find it. I don't
> think, this causes the problem.
> 
> Has anyone an idea what is my mistake?
> 
> BTW: I started the container without lxd and tried lxc-checkpoint and
> got the same errors. So I think it is not related to lxd but probably
> to criu?
> 
> Best regards
> 
> Dirk
> 
> -- 
> +----------------------------------------------------------------------+
> | Dr. Dirk Geschke       / Plankensteinweg 61    / 85435 Erding        |
> | Telefon: 08122-559448  / Mobil: 0176-96906350 / Fax: 08122-9818106   |
> | dirk at geschke-online.de / dirk at lug-erding.de  / kontakt at lug-erding.de |
> +----------------------------------------------------------------------+
> _______________________________________________
> lxc-users mailing list
> lxc-users at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-users


More information about the lxc-users mailing list