I am unable to exec a new process inside of an existing container. I have seen similar issues reported, but none of the solutions seems to have made a difference in my case. This last worked for me on Docker 1.10.3, prior to the introduction of runc. Since then, it has consistently failed.
[x] This is a bug report
[ ] This is a feature request
[X] I searched existing issues before opening this one
Note that the OS was recently upgraded from Ubuntu Trusty to Xenial. The behavior is the same under both. I have tried removing and reinstalling Docker but that has not helped.
Expected behavior
docker exec -it <container> bash should allow me to run bash from within the specified container.
Actual behavior
Fails with:
rpc error: code = 2 desc = oci runtime error: exec failed: container_linux.go:262: starting container process caused "process_linux.go:81: executing setns process caused \"exit status 16\""
I tried using docker-runc directly:
sudo docker-runc --debug exec 31c58169d1b77f618d7a03243377105677c387ee341e2c62ef5d946e94d09a7b ps
nsenter: failed to setns to /proc/9274/ns/ipc: Invalid argument
exec failed: container_linux.go:262: starting container process caused "process_linux.go:81: executing setns process caused \"exit status 16\""
Steps to reproduce the behavior
Try to run a command in any existing container. It fails with the error above. Note that I am able to use docker run -it --rm alpine sh to get a shell in a newly created container.
Output of docker version:
Client:
Version: 17.06.0-ce
API version: 1.30
Go version: go1.8.3
Git commit: 02c1d87
Built: Fri Jun 23 21:23:31 2017
OS/Arch: linux/amd64
Server:
Version: 17.06.0-ce
API version: 1.30 (minimum version 1.12)
Go version: go1.8.3
Git commit: 02c1d87
Built: Fri Jun 23 21:19:04 2017
OS/Arch: linux/amd64
Experimental: false
I am unable to exec a new process inside of an existing container. I have seen similar issues reported, but none of the solutions seems to have made a difference in my case. This last worked for me on Docker 1.10.3, prior to the introduction of runc. Since then, it has consistently failed.
Note that the OS was recently upgraded from Ubuntu Trusty to Xenial. The behavior is the same under both. I have tried removing and reinstalling Docker but that has not helped.
Expected behavior
docker exec -it <container> bash
should allow me to run bash from within the specified container.Actual behavior
Fails with:
rpc error: code = 2 desc = oci runtime error: exec failed: container_linux.go:262: starting container process caused "process_linux.go:81: executing setns process caused \"exit status 16\""
I tried using docker-runc directly:
Steps to reproduce the behavior
Try to run a command in any existing container. It fails with the error above. Note that I am able to use
docker run -it --rm alpine sh
to get a shell in a newly created container.Output of
docker version
:Output of
docker info
:Additional environment details (AWS, VirtualBox, physical, etc.)
This is running on physical hardware (Lenovo ThinkPad W541).