-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Handling Pausing from freezer state #218
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
As it stands with 48dd4af, here's the current mapping from
I'd suggest we update our Go constants to reflect the kernel's values:
so folks can distinguish between THAWED and FREEZING. But I'm not |
|
@wking @crosbymichael @LK4D4 |
|
On Fri, Aug 21, 2015 at 10:25:26AM -0700, Rajasekaran wrote:
I'm not a maintainer (just adding my perspective as a user), so I Maybe this sort of model discussion should happen on the mailing list |
|
@rajasec this looks good as a way to find out if the container is frozen. Lets factor out this code into a separate function and make sure that we have a specific error type if a system does not support the freezer cgroup. We don't want to the state method to fail if a system does not support freezer. So make sure you check for an IsNotExist error and ignore it in here. |
|
@crosbymichael |
|
@crosbymichael @wking |
|
On Sat, Aug 22, 2015 at 10:34:14AM -0700, W. Trevor King wrote:
I also added another fixup to that PR (wking/runc@6f3b1d2ea3) that |
|
@wking @crosbymichael |
|
On Sat, Aug 22, 2015 at 08:17:04PM -0700, Rajasekaran wrote:
Right, in 1 I was just referencing your original commit.
The explicit !ok check in wking/runc@6f3b1d2 (part of my fixup With your current b73aef5, you don't distinguish between “we don't |
|
@crosbymichael |
libcontainer/container_linux.go
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you are missing a return 0, err here
|
@crosbymichael
Mainly for the first point to handle system without freezer subsystem. Even I thought that the same thing, it seems little odd for return Running. |
|
On Fri, Aug 28, 2015 at 08:49:17PM -0700, Rajasekaran wrote:
(2) is just an instance of (1), so the comment can be just: if os.IsNotExist(err) { |
Signed-off-by: Rajasekaran <[email protected]> freezer status Signed-off-by: Rajasekaran <[email protected]> Fixing review comments Signed-off-by: Rajasekaran <[email protected]> Added comment when freezer not available Signed-off-by: Rajasekaran <[email protected]>
b73aef5 to
53dbdc6
Compare
|
@crosbymichael |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we should check both FROZEN and FREEZING here, we have pausing defined but never used, it should be returned here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On Mon, Sep 07, 2015 at 12:01:35AM -0700, Qiang Huang wrote:
Maybe we should check both
FROZENandFREEZINGhere, we have
pausingdefined but never used, it should be returned here.
Previous thoughts on model state settings in [1,2,3]. But if we
already have state constants for each of Linux's three settings, I
think it makes sense to use them (at least until the runtime-agnostic
spec has something to say about freezing).
|
@hqhq |
|
@crosbymichael |
Remove trailing comma in hooks json example
@crosbymichael @mrunalp
With current runc implementation, container pause is handled from the config file, Added the contents to handle from the freezer subsystem and its freezer.state from the respective container.
This is to handle #217 which has been raised
Signed-off-by: Rajasekaran [email protected]