Bug 1174060 - Can't get a shell into running container under Docker 1.4.0
Summary: Can't get a shell into running container under Docker 1.4.0
Keywords:
Status: CLOSED CANTFIX
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: docker-io
Version: el6
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Lokesh Mandvekar
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-12-15 02:51 UTC by afoxson
Modified: 2014-12-20 09:01 UTC (History)
13 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2014-12-20 09:01:51 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description afoxson 2014-12-15 02:51:12 UTC
Description of problem:

The following issue manifests under 1.4.0, yet does not manifest under 1.3.3 (nor does it manifest under 1.3.2), on CentOS 6.6. Attempting to get a shell into a running container is failing.

Version-Release number of selected component (if applicable):

docker-io-1.4.0-1.el6.x86_64.rpm

How reproducible:

The issue can be reproduced consistently.

Steps to Reproduce:
1. Execute, e.g.: sudo docker exec -it foo /bin/bash

Actual results:

"Cannot run exec command b13d5583ef1c0661e7db21bfaa164c421b50ef18248c727b99fc5426a8ccd055 in container a51df7ec54884cd5c473f1a0c4097865806abb66139fb53544ed116f4fa87264: write parent: broken pipe Error starting exec command in container b13d5583ef1c0661e7db21bfaa164c421b50ef18248c727b99fc5426a8ccd055: Cannot run exec command b13d5583ef1c066"

Expected results:

A bash shell running in container.

Additional info:

/var/log/docker contains "time="2014-12-14T16:27:58-05:00" level="error" msg="Handler for POST /exec/{name:.*}/resize returned error: bad file descriptor""

$ sudo docker version
Client version: 1.4.0
Client API version: 1.16
Go version (client): go1.3.3
Git commit (client): 4595d4f/1.4.0
OS/Arch (client): linux/amd64
Server version: 1.4.0
Server API version: 1.16
Go version (server): go1.3.3
Git commit (server): 4595d4f/1.4.0
$

Comment 1 afoxson 2014-12-20 09:01:51 UTC
"Docker exec does not work on 2.6 kernels, it needs 3.8 to support setns fully, it's a kernel requirement"

For more information, see:

https://github.com/docker/docker/issues/9680#issuecomment-67372683

The following is available as an alternative:

https://github.com/jpetazzo/nsenter


Note You need to log in before you can comment on or make changes to this bug.