From 5061fd3e6e1338f797e1090b7f5146bca6ed3c0b Mon Sep 17 00:00:00 2001 From: Ma Shimiao Date: Thu, 7 Dec 2017 15:43:56 +0800 Subject: [PATCH] stopped container can't be checkpoint Signed-off-by: Ma Shimiao --- checkpoint.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/checkpoint.go b/checkpoint.go index 41c2ac56..e7c12674 100644 --- a/checkpoint.go +++ b/checkpoint.go @@ -56,8 +56,8 @@ checkpointed.`, if err != nil { return err } - if status == libcontainer.Created { - fatalf("Container cannot be checkpointed in created state") + if status == libcontainer.Created || status == libcontainer.Stopped { + fatalf("Container cannot be checkpointed in %s state", status.String()) } defer destroy(container) options := criuOptions(context)