moby: Cannot exec into docker container ("containerd: process not found for container")
Output of docker version
:
Docker version 1.11.1, build 5604cbe
Output of docker info
:
Containers: 8
Running: 6
Paused: 0
Stopped: 2
Images: 14
Server Version: 1.11.1
Storage Driver: aufs
Root Dir: /var/lib/docker/aufs
Backing Filesystem: extfs
Dirs: 87
Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge null host
Kernel Version: 3.16.0-67-generic
Operating System: Ubuntu 14.04.4 LTS
OSType: linux
Architecture: x86_64
CPUs: 8
Total Memory: 15.31 GiB
Name: agyantdev
ID: XSB4:V4GP:MKT2:R3U5:7P3B:ZPPA:AOLJ:6AYU:SCS4:SYXI:B73D:YA6J
Docker Root Dir: /var/lib/docker
Debug mode (client): true
Debug mode (server): false
Registry: https://index.docker.io/v1/
WARNING: No swap limit support
Steps to reproduce the issue:
- installed docker
- started an image successfully
- ran : sudo docker exec -it CONTAINER_NAME /bin/bash also tried bash, bin/bash, sh, bin/sh, /bin/sh, ect
Describe the results you received: time=“2016-05-23T15:26:43.731439437+01:00” level=error msg=“Error running exec in container: rpc error: code = 2 desc = "oci runtime error: exec failed: exit status 1"\n” time=“2016-05-23T15:26:43.731481314+01:00” level=error msg=“Handler for POST /v1.23/exec/4e370de345ab1b06504c1242375c3b41e4b5ecd843aa486b54d288803e1f402a/start returned error: rpc error: code = 2 desc = "oci runtime error: exec failed: exit status 1"” 2016/05/23 15:26:43 http: response.WriteHeader on hijacked connection 2016/05/23 15:26:43 http: response.Write on hijacked connection time=“2016-05-23T15:26:43.731718484+01:00” level=error msg=“Handler for POST /v1.23/exec/4e370de345ab1b06504c1242375c3b41e4b5ecd843aa486b54d288803e1f402a/resize returned error: rpc error: code = 2 desc = "containerd: processs not found for container"”
Describe the results you expected: SSH terminal of the machine
Additional information you deem important (e.g. issue happens only occasionally): Uninstalled and installed docker-engine multiple times
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 57 (26 by maintainers)
@agyanttiwari if that’s the
testing
container from my earlier example, be sure to usesh
, notbash
, because thealpine
image doesn’t have bash, only shI used to manage this issue by simply restarting the docker daemon:
ubuntu@myserver:~$ sudo docker exec -it 3c0874121e1e /bin/bash
rpc error: code = 2 desc = containerd: container not found
ubuntu@myserver:~$ sudo systemctl restart docker
ubuntu@myserver:~$ docker exec -it 3c0874121e1e /bin/bash
root@3c0874121e1e:/#
@Miyurz the prometheus image is based on busybox; https://hub.docker.com/r/prom/prometheus/~/dockerfile/, which doesn’t have bash. Try
sh
instead;Ok, i investigated it a bit - the problem doesn’t exist in version 1.10.3-0, it starts at version 1.11.0, which means that it happens in 1.11.0 and 1.11.1 I’ve tried to install each version and to see where it happens.