[CRIU] LXC checkpoint/restore HOWTO using upstream tools

Tycho Andersen tycho.andersen at canonical.com
Fri Sep 19 06:26:47 PDT 2014


On Fri, Sep 19, 2014 at 11:17:55AM +0400, Pavel Emelyanov wrote:
> On 09/19/2014 04:39 AM, Tycho Andersen wrote:
> > Hi all,
> > 
> > It seems there is more interest in doing checkpoint/restore of LXCs. I
> > have written a little howto about how to use the upstream LXC tools
> > with criu integration do do this:
> > 
> > http://www.criu.org/LXC#Using_LXC_Upstream_tools
> 
> That's awesome! Thank you for that.
> 
> Did you implement the "reattach" facility when restore container
> got reattached back to the lxc daemon?

Yes, all of that should work. Ideally it would be totally transparent
that you've resumed a container via lxc-checkpoint -r instead of
started it via lxc-start. There are three bugs about this that I know
if right now:

* You can't checkpoint containers that have been restored. This is the
  tty bug that Cyrill and I talked about a while ago.
* Possibly related, when you try and lxc-stop a restored container, it
  hangs once the container is stopped and leaves a getty that is
  taking 100% CPU.
* There is some small bug with how the cgroups are reattached when
  they are co-mounted. I am going to look into this today.

Tycho


More information about the CRIU mailing list