Can't connect to SSH
Closed this issue · 9 comments
I need to examine build https://jenkins.open-scap.org/job/openscap-pull-requests/298/ of OpenSCAP/openscap#276, but I am not able to connect to ssh on it. Firstly I thought that simply my home network ISP doesn't allows such connection, but now it does not work also from office. SSH gives an error message. Here is the verbose output.
[jcerny@thinkpad ~]$ ssh -v 'jan-cerny@298#openscap-pull-requests.jenkins.open-scap.org'
OpenSSH_7.1p1, OpenSSL 1.0.2e-fips 3 Dec 2015
debug1: Reading configuration data /home/jcerny/.ssh/config
debug1: /home/jcerny/.ssh/config line 5: Applying options for *.jenkins.open-scap.org
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 56: Applying options for *
debug1: Executing proxy command: exec ssh -q -p 56917 jenkins.open-scap.org diagnose-tunnel -suffix .jenkins.open-scap.org 298#openscap-pull-requests.jenkins.open-scap.org
debug1: permanently_drop_suid: 1000
debug1: identity file /home/jcerny/.ssh/id_rsa type 1
debug1: key_load_public: No such file or directory
debug1: identity file /home/jcerny/.ssh/id_rsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/jcerny/.ssh/id_dsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/jcerny/.ssh/id_dsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/jcerny/.ssh/id_ecdsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/jcerny/.ssh/id_ecdsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/jcerny/.ssh/id_ed25519 type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/jcerny/.ssh/id_ed25519-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_7.1
ssh_exchange_identification: Connection closed by remote host
It doesn't work also for other builds.
@jan-cerny
Works for me (for the case ssh -v 'iankko@298#openscap-pull-requests.jenkins.open-scap.org'
) => IMHO this is not a bug in the infrastructure, but rather issue of configuration.
Have you shared your public key with Zbynek? If so, it's possible he didn't apply that key yet (AFAIK you should have received an email from Zbynek once the key got published).
@iankko OK, I apologize I did not know that I have to send my key to Zbyněk. I did not know that there was a change in the key policy. It worked before so I thought it just suddenly stopped working.
AFAIK you don't have to send your public key to Zbynek to access the jobs via ssh. You have to set it via the Jenkins web interface. Most likely you have already done that.
@mpreisler I have my public key in web interface. I have it already there for several months. I have checked it again and it really is my public key. Have some permissions been changed on Jenkins during Christmas?
Have some permissions been changed on Jenkins during Christmas?
As far as I know permissions haven't changed. The reason why @ybznek asked for SSH public keys is so that more people can ssh into the master machine directly and help him administer it. It is not necessary for normal Jenkins operations like logging into a job.
@mpreisler I understand. It seems like a issue of my machine.
@jan-cerny, This is what I have in the .ssh/config
.
Host=*.jenkins.open-scap.org
user isimluk
Port=56917
ProxyCommand=ssh -q -p 56917 jenkins.open-scap.org diagnose-tunnel -suffix .jenkins.open-scap.org %h
IdentityFile ~/.ssh/id_rsa2
having the IdentityFile
specified may help, when you have so many ssh keys on your system and only one uploaded to jenkins. Also, please note that your system user name is different from your github username. You'll need to find right combination.
Most likely user issue.