Skip to content

"rke up" got "ssh: rejected: administratively prohibited (open failed)" #93

Closed
@nevermosby

Description

@nevermosby

rke version: rke version v0.0.7-dev

problem:
when to run "./rke -d up" with the file "cluster.yml" in the same folder, I got:

INFO[0000] [certificates] Generating kubernetes certificates
INFO[0000] [certificates] Generating CA kubernetes certificates
...
INFO[0003][certificates] Deploying kubernetes certificates to Cluster nodes
DEBU[0003] [certificates] Pulling Certificate downloader Image on host [node1]
FATA[0008] Can't pull Docker image rancher/rke-cert-deployer:0.1.0 for host [node1]: error during connect: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.24/images/create?fromImage=rancher%2Frke-cert-deployer&tag=0.1.0: Error connecting to Docker socket on host [node1]: ssh: rejected: administratively prohibited (open failed)

Tried to fix it by enabling the ssh config,AllowTcpForwarding yes, but failed.

Any suggestions?

Activity

superseb

superseb commented on Dec 3, 2017

@superseb
Contributor

Is this on CentOS/RHEL by any chance?

galal-hussein

galal-hussein commented on Dec 3, 2017

@galal-hussein
Contributor

Can you also make sure that the ssh user you are using has access to docker engine

iyacontrol

iyacontrol commented on Dec 4, 2017

@iyacontrol

i also meet the same problem。i even try root user to ssh ,but the rke still failed。

iyacontrol

iyacontrol commented on Dec 4, 2017

@iyacontrol

@nevermosby have you solved the problem?

superseb

superseb commented on Dec 4, 2017

@superseb
Contributor

@iyacontrol Please share used OS (cat /etc/os-release)

iyacontrol

iyacontrol commented on Dec 4, 2017

@iyacontrol

@superseb
NAME="CentOS Linux"
VERSION="7 (Core)"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="7"
PRETTY_NAME="CentOS Linux 7 (Core)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:centos:centos:7"
HOME_URL="https://www.centos.org/"
BUG_REPORT_URL="https://bugs.centos.org/"

CENTOS_MANTISBT_PROJECT="CentOS-7"
CENTOS_MANTISBT_PROJECT_VERSION="7"
REDHAT_SUPPORT_PRODUCT="centos"
REDHAT_SUPPORT_PRODUCT_VERSION="7"

iyacontrol

iyacontrol commented on Dec 4, 2017

@iyacontrol

@superseb Linux 3.10.0-693.el7.x86_64

nevermosby

nevermosby commented on Dec 4, 2017

@nevermosby
Author

@superseb yeah, it is a centos system, details are listed beblow:

NAME="CentOS Linux"
VERSION="7 (Core)"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="7"
PRETTY_NAME="CentOS Linux 7 (Core)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:centos:centos:7"
HOME_URL="https://www.centos.org/"
BUG_REPORT_URL="https://bugs.centos.org/"

CENTOS_MANTISBT_PROJECT="CentOS-7"
CENTOS_MANTISBT_PROJECT_VERSION="7"
REDHAT_SUPPORT_PRODUCT="centos"
REDHAT_SUPPORT_PRODUCT_VERSION="7"

@galal-hussein I used "root" to run the command so it can be sure I have the access to docker engine.

@iyacontrol I still have this issue with centos.

New progress here:
I tried ubuntu system instead and it did work.
So some different OS configuration can be the root cause.

galal-hussein

galal-hussein commented on Dec 4, 2017

@galal-hussein
Contributor

@nevermosby I will try to reproduce with CentOS 7 to see if the problem is related to specific OS

galal-hussein

galal-hussein commented on Dec 5, 2017

@galal-hussein
Contributor

@nevermosby @iyacontrol @superseb I was able to reproduce the issue, however i am not sure what is the root cause, CentOS seems to reject ssh local forwarding using the root:

- Unit session-33.scope has begun starting up.
Dec 04 23:32:46 hussein-centos-01 sshd[11192]: refused streamlocal port forward: originator  port 0, target /var/run/docker.sock
Dec 04 23:32:46 hussein-centos-01 sshd[11192]: pam_unix(sshd:session): session closed for user root
➜  ssh -nNT -L /tmp/docker.sock:/var/run/docker.sock  root@x.x.x.x
channel 1: open failed: administratively prohibited: open failed
channel 1: open failed: administratively prohibited: open failed

however it works for another users other than root, for a work around you can specify other users than root for now

nevermosby

nevermosby commented on Dec 5, 2017

@nevermosby
Author

@galal-hussein thx for feedback. On the same centos machine, I took ur advice and tried another user other than root but got same error.

galal-hussein

galal-hussein commented on Dec 5, 2017

@galal-hussein
Contributor

@nevermosby can you make sure that the ssh user has access to docker engine, you can add the user to docker group and use it in cluster.yml

nevermosby

nevermosby commented on Dec 5, 2017

@nevermosby
Author

@galal-hussein yes I am sure I have added the user to docker group and tried "docker push" command, it works.fine.

galal-hussein

galal-hussein commented on Dec 5, 2017

@galal-hussein
Contributor

@nevermosby Can you post the version of openssh currently installed on the centos server

14 remaining items

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @niusmallnan@ibre5041@nevermosby@subhransusekhar@superseb

        Issue actions

          "rke up" got "ssh: rejected: administratively prohibited (open failed)" · Issue #93 · rancher/rke