Comments (2)
Would it make sense to create a new context in the defer?
Did you have something else in mind for this?
from cri.
We actually hit this.
In the test failure https://k8s-gubernator.appspot.com/build/kubernetes-jenkins/logs/ci-cri-containerd-node-e2e-serial/343, kubelet got restarted in the middle of the test, and all on-going contexts got cancelled.
After that, task being started was left in a weird state, because all cleanup operations failed:
time="2018-03-06T22:50:42Z" level=info msg="StartContainer for "b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293""
time="2018-03-06T22:50:42Z" level=debug msg="Start writing log file "/var/log/pods/cbf9f844-2190-11e8-b64e-42010a80001f/guaranteedcbf1db79-2190-11e8-a254-42010a80001f/0.log""
time="2018-03-06T22:50:42Z" level=debug msg="Start writing log file "/var/log/pods/cbf9f844-2190-11e8-b64e-42010a80001f/guaranteedcbf1db79-2190-11e8-a254-42010a80001f/0.log""
time="2018-03-06T22:50:42Z" level=debug msg="get snapshot mounts" key=b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293
time="2018-03-06T22:50:42Z" level=info msg="shim /home/containerd/usr/local/bin/containerd-shim started" address="/containerd-shim/k8s.io/b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293/shim.sock" debug=false pid=14405
time="2018-03-06T22:50:42Z" level=debug msg="event published" ns=k8s.io topic="/tasks/create" type=containerd.events.TaskCreate
time="2018-03-06T22:50:42Z" level=error msg="Failed to pipe stdout of container "b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293"" error="read /proc/self/fd/18: file already closed"
time="2018-03-06T22:50:42Z" level=error msg="Failed to pipe stderr of container "b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293"" error="read /proc/self/fd/24: file already closed"
time="2018-03-06T22:50:42Z" level=error msg="Failed to delete containerd task "b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293"" error="context canceled: unknown"
time="2018-03-06T22:50:42Z" level=info msg="Finish piping stdout of container "b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293""
time="2018-03-06T22:50:42Z" level=debug msg="Finish redirecting log file "/var/log/pods/cbf9f844-2190-11e8-b64e-42010a80001f/guaranteedcbf1db79-2190-11e8-a254-42010a80001f/0.log""
time="2018-03-06T22:50:42Z" level=info msg="Finish piping stderr of container "b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293""
time="2018-03-06T22:50:42Z" level=debug msg="Finish redirecting log file "/var/log/pods/cbf9f844-2190-11e8-b64e-42010a80001f/guaranteedcbf1db79-2190-11e8-a254-42010a80001f/0.log""
time="2018-03-06T22:50:42Z" level=error msg="StartContainer for "b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293" failed" error="failed to start containerd task "b15874cb3bedc785ae0a0186f266cb60d33b473e3819f569bffc80313cda4293": context canceled: unknown"
We should fix this.
Would it make sense to create a new context in the defer?
Did you have something else in mind for this?
@cpuguy83 Sorry for missing your reply... Yeah, as you said, we should create a new context for cleanup in defer.
from cri.
Related Issues (20)
- Problems with exec - differences between dockershim and containerd
- Release tarballs for v1.3.5 and v1.3.6 not published HOT 9
- please delete
- Latest Windows runner in github actions is failing HOT 2
- Pods stuck in container creating on enabling CNI chaining HOT 8
- container list pod id filter should support short pod id
- containerd.service should be pulled from containerd repo HOT 2
- Support for ephemeral containers .. NamespaceMode=Target HOT 2
- Unable to pull image from Insecure Registry on GKE HOT 14
- Some nodes on GKE giving archive/tar: invalid tar header: unknown HOT 5
- Default values for masked and readonly paths are not used for container creation
- Pod stuck Terminated always util `ctr t rm {}` HOT 1
- containerd config default brings old config that gives warning in daemon HOT 1
- Trying to redirect to a different path on a alternative registry HOT 8
- Help need to add a private registry to containerd / k3s HOT 2
- archive docs and point to new location
- mirror and tls configuration are mutually exclusive HOT 1
- golang 1.6
- contain-nerd-B4L HOT 3
- StopContainer silently ignored when container is in CONTAINER_CREATED state HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cri.