-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[release/1.2] Fix process locking and state management #2803
[release/1.2] Fix process locking and state management #2803
Conversation
There were races with the way process states. This displayed in ways, especially around pausing the container for atomic operations. Users would get errors like, cannnot delete container in paused state and such. This can be eaisly reproduced with `docker` and the following command: ```bash > (for i in `seq 1 25`; do id=$(docker create alpine usleep 50000);docker start $id;docker commit $id;docker wait $id;docker rm $id; done) ``` This two issues that this fixes are: * locks must be held by the owning process, not the state operations. * If a container ends up being paused but before the operation completes, the process exists, make sure we resume the container before setting the the process as exited. Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Codecov Report
@@ Coverage Diff @@
## release/1.2 #2803 +/- ##
============================================
Coverage 43.74% 43.74%
============================================
Files 100 100
Lines 10728 10728
============================================
Hits 4693 4693
Misses 5305 5305
Partials 730 730
Continue to review full report at Codecov.
|
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.
LGTM
backport of #2773 |
LGTM |
Signed-off-by: Lantao Liu <lantaol@google.com>
Signed-off-by: Lantao Liu <lantaol@google.com>
* Update containerd to 1.2.2 Signed-off-by: Lantao Liu <lantaol@google.com> * Port containerd/containerd#2803. Signed-off-by: Lantao Liu <lantaol@google.com>
There were races with the way process states. This displayed in ways,
especially around pausing the container for atomic operations. Users
would get errors like, cannnot delete container in paused state and
such.
This can be eaisly reproduced with
docker
and the following command:This two issues that this fixes are:
completes, the process exists, make sure we resume the container before
setting the the process as exited.
Signed-off-by: Michael Crosby crosbymichael@gmail.com