Bug 1656083

Summary: oc rsh fails for all containers built from dockerfile
Product: OpenShift Container Platform Reporter: ktenzer
Component: ContainersAssignee: Mrunal Patel <mpatel>
Status: CLOSED ERRATA QA Contact: weiwei jiang <wjiang>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 3.11.0CC: aos-bugs, jokerman, lxia, mmccomas, rbohne, weliang
Target Milestone: ---   
Target Release: 3.11.z   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-26 09:07:54 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description ktenzer 2018-12-04 16:20:50 UTC
Description of problem:

cloud-user@bastion home]$ oc rsh openshift-fedora-stress-1-89g5x
rpc error: code = 2 desc = oci runtime error: exec failed: container_linux.go:247: starting container process caused "process_linux.go:110: decoding init error from pipe caused \"read parent: connection reset by peer\""


Version-Release number of selected component (if applicable):
OCP 3.11 using docker-1.13.1-84.git07f3374.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. oc new-app https://github.com/ktenzer/openshift-fedora-stress.git
2. [cloud-user@bastion home]$ oc get pods
NAME                              READY     STATUS      RESTARTS   AGE
openshift-fedora-stress-1-89g5x   1/1       Running     0          2m
3. oc rsh openshift-fedora-stress-1-89g5x

Actual results:
rpc error: code = 2 desc = oci runtime error: exec failed: container_linux.go:247: starting container process caused "process_linux.go:110: decoding init error from pipe caused \"read parent: connection reset by peer\""


Expected results:
I expect a command prompt inside container.


Additional info:

Comment 1 Robert Bohne 2018-12-04 16:47:12 UTC
With centos image it works very well, with federo image i got the same problem:

[root@node1 test]# docker version
Client:
 Version:         1.13.1
 API version:     1.26
 Package version: docker-1.13.1-84.git07f3374.el7.x86_64
 Go version:      go1.10.2
 Git commit:      07f3374/1.13.1
 Built:           Tue Nov  6 18:41:32 2018
 OS/Arch:         linux/amd64

Server:
 Version:         1.13.1
 API version:     1.26 (minimum version 1.12)
 Package version: docker-1.13.1-84.git07f3374.el7.x86_64
 Go version:      go1.10.2
 Git commit:      07f3374/1.13.1
 Built:           Tue Nov  6 18:41:32 2018
 OS/Arch:         linux/amd64
 Experimental:    false

[root@node1 test]# cat Dockerfile
FROM fedora:latest
CMD while true ; do date; sleep 1; done;

[root@node1 test]# docker build -q .
sha256:863429ac88073921ad0e05251914a0e0256e34f2386b0b61b093ffdd7713d9cb
[root@node1 test]# docker run -d sha256:863429ac88073921ad0e05251914a0e0256e34f2386b0b61b093ffdd7713d9cb
e7a09e8fc3a85e70dc72be16834c68012c13d3ba1a7a29571e4ab0a2c7f2c53e
docker [root@node1 test]# docker exec -ti e7a09e8fc3a85e70dc72be16834c68012c13d3ba1a7a29571e4ab0a2c7f2c53e bash
rpc error: code = 2 desc = oci runtime error: exec failed: container_linux.go:247: starting container process caused "process_linux.go:110: decoding init error from pipe caused \"read parent: connection reset by peer\""

[root@node1 test]# cat Dockerfile
FROM centos
CMD while true ; do date; sleep 1; done;
[root@node1 test]# docker build -q .
sha256:9524be5a093b2ee44303259d72d671b028b55b28446ad11c498b93d2e4a5338e
[root@node1 test]# docker run -d sha256:9524be5a093b2ee44303259d72d671b028b55b28446ad11c498b93d2e4a5338e
50d0e886198b6348154ca4bd20aeb407115a5b0a294ca9387ff5ab8889a4be02
[root@node1 test]# docker exec -ti 50d0e886198b6348154ca4bd20aeb407115a5b0a294ca9387ff5ab8889a4be02 bash
[root@50d0e886198b /]# exit
exit


[root@node1 test]# docker inspect centos | grep Id
        "Id": "sha256:75835a67d1341bdc7f4cc4ed9fa1631a7d7b6998e9327272afea342d90c4ab6d",
[root@node1 test]# docker inspect fedora | grep Id
        "Id": "sha256:8c568f1043264e34f0a8774587266565c7e5e54e9ea6b97ab459086d18ac5175",
[root@node1 test]#

Comment 2 Weibin Liang 2018-12-04 20:29:57 UTC
oc rsh pod failed too when container use openshift/hello-openshift image

[root@qe-weliang-310-policymaster-etcd-nfs-1 ~]# oc version
oc v3.10.83
kubernetes v1.10.0+b81c8f8
features: Basic-Auth GSSAPI Kerberos SPNEGO

Server https://qe-weliang-310-policymaster-etcd-nfs-1:8443
openshift v3.10.83
kubernetes v1.10.0+b81c8f8
[root@qe-weliang-310-policymaster-etcd-nfs-1 ~]# oc rsh blue-pod-5
rpc error: code = 2 desc = oci runtime error: exec failed: container_linux.go:247: starting container process caused "process_linux.go:110: decoding init error from pipe caused \"read parent: connection reset by peer\""

command terminated with exit code 126
[root@qe-weliang-310-policymaster-etcd-nfs-1 ~]#

Comment 3 Mrunal Patel 2019-01-14 21:43:05 UTC
This is fixed in build -88 and up.

Comment 4 weiwei jiang 2019-01-28 05:04:02 UTC
Verified on 
[openshift@master-0 ~]$ oc version 
oc v3.11.74
kubernetes v1.11.0+d4cacc0
features: Basic-Auth GSSAPI Kerberos SPNEGO

Server https://192.168.99.11:8443
openshift v3.11.74
kubernetes v1.11.0+d4cacc0
[openshift@master-0 ~]$ oc get nodes -o wide 
NAME                                  STATUS    ROLES     AGE       VERSION           INTERNAL-IP     EXTERNAL-IP    OS-IMAGE                                      KERNEL-VERSION              CONTAINER-RUNTIME
app-node-0.wjiang-ocp.example.com     Ready     compute   1h        v1.11.0+d4cacc0   192.168.99.14   10.8.251.135   Red Hat Enterprise Linux Server 7.6 (Maipo)   3.10.0-957.1.3.el7.x86_64   docker://1.13.1
infra-node-0.wjiang-ocp.example.com   Ready     infra     1h        v1.11.0+d4cacc0   192.168.99.9    10.8.250.45    Red Hat Enterprise Linux Server 7.6 (Maipo)   3.10.0-957.1.3.el7.x86_64   docker://1.13.1
master-0.wjiang-ocp.example.com       Ready     master    1h        v1.11.0+d4cacc0   192.168.99.11   10.8.251.178   Red Hat Enterprise Linux Server 7.6 (Maipo)   3.10.0-957.1.3.el7.x86_64   docker://1.13.1
master-1.wjiang-ocp.example.com       Ready     master    1h        v1.11.0+d4cacc0   192.168.99.16   10.8.246.139   Red Hat Enterprise Linux Server 7.6 (Maipo)   3.10.0-957.1.3.el7.x86_64   docker://1.13.1
[openshift@master-0 ~]$ rpm -qa|grep -i docker
atomic-openshift-docker-excluder-3.11.74-1.git.0.d68ca3e.el7.noarch
docker-client-1.13.1-88.git07f3374.el7.x86_64
docker-common-1.13.1-88.git07f3374.el7.x86_64
docker-1.13.1-88.git07f3374.el7.x86_64
python-docker-pycreds-0.3.0-7.el7.noarch
python-docker-2.4.2-1.3.el7.noarch
docker-rhel-push-plugin-1.13.1-88.git07f3374.el7.x86_64

Comment 6 errata-xmlrpc 2019-06-26 09:07:54 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:1605