Skip to content

Allow to checkpoint and restore a container with console#2307

Merged
crosbymichael merged 4 commits intocontainerd:masterfrom
avagin:tty
Apr 30, 2018
Merged

Allow to checkpoint and restore a container with console#2307
crosbymichael merged 4 commits intocontainerd:masterfrom
avagin:tty

Conversation

@avagin
Copy link
Copy Markdown
Contributor

@avagin avagin commented Apr 24, 2018

runc already supports this case, so we just need to run it with proper
options.

Signed-off-by: Andrei Vagin [email protected]

@codecov-io
Copy link
Copy Markdown

codecov-io commented Apr 24, 2018

Codecov Report

Merging #2307 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #2307   +/-   ##
=======================================
  Coverage   45.41%   45.41%           
=======================================
  Files          83       83           
  Lines        9210     9210           
=======================================
  Hits         4183     4183           
  Misses       4351     4351           
  Partials      676      676
Flag Coverage Δ
#linux 49.9% <ø> (ø) ⬆️
#windows 41.24% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cddd791...29c76b1. Read the comment docs.

@crosbymichael
Copy link
Copy Markdown
Member

crosbymichael commented Apr 24, 2018

LGTM

Nice thanks! I'll add a test for this if you don't have time to add one.

Copy link
Copy Markdown
Member

@estesp estesp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@avagin
Copy link
Copy Markdown
Contributor Author

avagin commented Apr 24, 2018

@crosbymichael If you have a test which start a container with console, I think I can write a test by myself.

It is my first time, when I'm playing with containerd, and I like this experience. The code base looks nice.

Comment thread linux/proc/init_state.go Outdated
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a way to block criu from starting the final container process until we signal it?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@crosbymichael Could you explain the idea of this barrier?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@crosbymichael I think I understand the problem, will think what we can do.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's to mimic the create/start split so there is time after the namespaces and process has been created before the user's process starts.

@crosbymichael
Copy link
Copy Markdown
Member

@avagin avagin force-pushed the tty branch 2 times, most recently from 956fed9 to 5017b4a Compare April 26, 2018 08:24
@crosbymichael
Copy link
Copy Markdown
Member

@avagin actually, for now can you move the restore functionality back into the Start method instead of create so that we keep the same API that the process is started when you call start and not when the container is created in the restore case?

@avagin
Copy link
Copy Markdown
Contributor Author

avagin commented Apr 27, 2018

@crosbymichael I will try. We are thinking how to split restore and start, but all solutions are not simple, so it's better to do as a separate task. Now I'm going to you move the restore functionality back into the Start method, and we will be able to merge this pull request.

Signed-off-by: Andrei Vagin <[email protected]>
@crosbymichael
Copy link
Copy Markdown
Member

Yep, we are merge when its moved back.

avagin added 3 commits April 28, 2018 01:06
runc already supports this case, so we just need to run it with proper
options.

Signed-off-by: Andrei Vagin <[email protected]>
Signed-off-by: Andrei Vagin <[email protected]>
@crosbymichael
Copy link
Copy Markdown
Member

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants