• Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • None
    • Jenkins 1.138.3
      ssh-slaves-plugin 1.29.1
      Java 1.8.0_171-8u171
      OS: Debian Stretch (Server and Jenkins Nodes)
    • ssh-slaves-1.29.2

      Starting with ssh-slaves-plugin 1.29.1, the SSH agent connection with all nodes fail.

      Logs on Jenkins (logfile):

      [11/21/18 09:38:38] SSH Launch of HOSTNAME on HOSTNAME failed in 391 ms
      

      Logs on Jenkins (UI):

      SSHLauncher{host='HOSTNAME', port=22, credentialsId='b1f94972-dfce-45d0-9cb1-f14e3dc324b9', jvmOptions='', javaPath='', prefixStartSlaveCmd='', suffixStartSlaveCmd='', launchTimeoutSeconds=210, maxNumRetries=10, retryWaitTime=15, sshHostKeyVerificationStrategy=hudson.plugins.sshslaves.verifiers.ManuallyTrustedKeyVerificationStrategy, tcpNoDelay=true, trackCredentials=true}
      [11/21/18 09:40:05] [SSH] Opening SSH connection to HOSTNAME:22.
      [11/21/18 09:40:05] [SSH] SSH host key matches key seen previously for this host. Connection will be allowed.
      [11/21/18 09:40:05] [SSH] Authentication failed.
      Authentication failed.
      [11/21/18 09:40:05] Launch failed - cleaning up connection
      [11/21/18 09:40:05] [SSH] Connection closed.
      

      The auth.log of a node just contains:

      Closed due to user request. [preauth]
      

      Downgrading to 1.28.1 fixes the issue.

        1. config.xml
          2 kB
        2. jenkins2.png
          jenkins2.png
          143 kB
        3. jenkins1.png
          jenkins1.png
          19 kB

          [JENKINS-54746] Can't connect via SSH on 1.29.1

          Florian P created issue -
          Darryl Pogue made changes -
          Component/s New: ssh-slaves-plugin [ 15578 ]
          Component/s Original: ssh-agent-plugin [ 17509 ]
          Description Original: Starting with ssh-agent-plugin 1.29.1, the SSH agent connection with all nodes fail.

          Logs on Jenkins (logfile):
          {code}
          [11/21/18 09:38:38] SSH Launch of HOSTNAME on HOSTNAME failed in 391 ms
          {code}

          Logs on Jenkins (UI):

          {code}
          SSHLauncher{host='HOSTNAME', port=22, credentialsId='b1f94972-dfce-45d0-9cb1-f14e3dc324b9', jvmOptions='', javaPath='', prefixStartSlaveCmd='', suffixStartSlaveCmd='', launchTimeoutSeconds=210, maxNumRetries=10, retryWaitTime=15, sshHostKeyVerificationStrategy=hudson.plugins.sshslaves.verifiers.ManuallyTrustedKeyVerificationStrategy, tcpNoDelay=true, trackCredentials=true}
          [11/21/18 09:40:05] [SSH] Opening SSH connection to HOSTNAME:22.
          [11/21/18 09:40:05] [SSH] SSH host key matches key seen previously for this host. Connection will be allowed.
          [11/21/18 09:40:05] [SSH] Authentication failed.
          Authentication failed.
          [11/21/18 09:40:05] Launch failed - cleaning up connection
          [11/21/18 09:40:05] [SSH] Connection closed.
          {code}


          The {{auth.log}} of a node just contains:
          {code}
          Closed due to user request. [preauth]
          {code}


          Downgrading to 1.28.1 fixes the issue.
          New: Starting with ssh-slaves-plugin 1.29.1, the SSH agent connection with all nodes fail.

          Logs on Jenkins (logfile):
          {code:java}
          [11/21/18 09:38:38] SSH Launch of HOSTNAME on HOSTNAME failed in 391 ms
          {code}
          Logs on Jenkins (UI):
          {code:java}
          SSHLauncher{host='HOSTNAME', port=22, credentialsId='b1f94972-dfce-45d0-9cb1-f14e3dc324b9', jvmOptions='', javaPath='', prefixStartSlaveCmd='', suffixStartSlaveCmd='', launchTimeoutSeconds=210, maxNumRetries=10, retryWaitTime=15, sshHostKeyVerificationStrategy=hudson.plugins.sshslaves.verifiers.ManuallyTrustedKeyVerificationStrategy, tcpNoDelay=true, trackCredentials=true}
          [11/21/18 09:40:05] [SSH] Opening SSH connection to HOSTNAME:22.
          [11/21/18 09:40:05] [SSH] SSH host key matches key seen previously for this host. Connection will be allowed.
          [11/21/18 09:40:05] [SSH] Authentication failed.
          Authentication failed.
          [11/21/18 09:40:05] Launch failed - cleaning up connection
          [11/21/18 09:40:05] [SSH] Connection closed.
          {code}
          The {{auth.log}} of a node just contains:
          {code:java}
          Closed due to user request. [preauth]
          {code}
          Downgrading to 1.28.1 fixes the issue.
          Environment Original: Jenkins 1.138.3
          ssh-agent-plugin 1.29.1
          Java 1.8.0_171-8u171
          OS: Debian Stretch (Server and Jenkins Nodes)
          New: Jenkins 1.138.3
          ssh-slaves-plugin 1.29.1
          Java 1.8.0_171-8u171
          OS: Debian Stretch (Server and Jenkins Nodes)

          notizblock I had the same problem and I could solve it by rebooting the machine (restarting the jenkins service did not solve the problem).

          Does not make much sense to me but – problem solved.

          Florian Bäuerle added a comment - notizblock I had the same problem and I could solve it by rebooting the machine (restarting the jenkins service did not solve the problem). Does not make much sense to me but – problem solved.

          Darryl Pogue added a comment -

          After updating the ssh slaves plugin to 1.29.1, Jenkins will not connect to any of my build agents, and it complains about data stored in an old format:

          ConversionException: Could not call com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource.readResolve() : anonymous is missing the Overall/RunScripts permission : Could not call com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource.readResolve() : anonymous is missing the Overall/RunScripts permission ---- Debugging information ---- message : Could not call com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource.readResolve() : anonymous is missing the Overall/RunScripts permission cause-exception : com.thoughtworks.xstream.converters.reflection.ObjectAccessException cause-message : Could not call com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource.readResolve() : anonymous is missing the Overall/RunScripts permission class : com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource required-type : com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource converter-type : hudson.util.RobustReflectionConverter path : /com.cloudbees.plugins.credentials.SystemCredentialsProvider/domainCredentialsMap/entry/java.util.concurrent.CopyOnWriteArrayList/com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey/privateKeySource line number : 21 -------------------------------

           

          Rebooting the Jenkins machine did not help, and neither has rebooting the build agent machines.

          Darryl Pogue added a comment - After updating the ssh slaves plugin to 1.29.1, Jenkins will not connect to any of my build agents, and it complains about data stored in an old format: ConversionException: Could not call com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource.readResolve() : anonymous is missing the Overall/RunScripts permission : Could not call com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource.readResolve() : anonymous is missing the Overall/RunScripts permission ---- Debugging information ---- message : Could not call com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource.readResolve() : anonymous is missing the Overall/RunScripts permission cause-exception : com.thoughtworks.xstream.converters.reflection.ObjectAccessException cause-message : Could not call com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource.readResolve() : anonymous is missing the Overall/RunScripts permission class : com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource required-type : com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey$UsersPrivateKeySource converter-type : hudson.util.RobustReflectionConverter path : /com.cloudbees.plugins.credentials.SystemCredentialsProvider/domainCredentialsMap/entry/java.util.concurrent.CopyOnWriteArrayList/com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey/privateKeySource line number : 21 -------------------------------   Rebooting the Jenkins machine did not help, and neither has rebooting the build agent machines.

          Also for me rebooting did not definitely solve the problem, it stopped working again.

          Downgraded to 1.28.1, problem seems to be solved (for now). Sorry for the noise.

          I'm running Jenkins on CentOS7 with openjdk 1.8.0_191.

          Florian Bäuerle added a comment - Also for me rebooting did not definitely solve the problem, it stopped working again. Downgraded to 1.28.1, problem seems to be solved (for now). Sorry for the noise. I'm running Jenkins on CentOS7 with openjdk 1.8.0_191.

          I had the same issue. SSH connection worked fine, upgrade from 1.28.1 to 1.29.1 and SSH connection failed with exactly the same output as in the bug description above:

          • [SSH] SSH host key matches key seen previously for this host. Connection will be allowed.
          • [SSH] Authentication failed.

          Downgraded to 1.28.1 and connection immediately works again.

          Pieter-Jan Busschaert added a comment - I had the same issue. SSH connection worked fine, upgrade from 1.28.1 to 1.29.1 and SSH connection failed with exactly the same output as in the bug description above: [SSH] SSH host key matches key seen previously for this host. Connection will be allowed. [SSH] Authentication failed. Downgraded to 1.28.1 and connection immediately works again.

          Makson Lee added a comment -

          we have the same issue too.

          Makson Lee added a comment - we have the same issue too.

          Hi all,

          Please note that update to 1.29.1 also causes Subversion Plugin (2.12.1) to fail on svn+ssh checkouts:

          org.tmatesoft.svn.core.SVNCancelException: svn: E200015: authentication cancelled
          	at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.cancel(SVNErrorManager.java:39)
          	at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.cancel(SVNErrorManager.java:34)
          	at org.tmatesoft.svn.core.internal.io.svn.SVNSSHConnector.open(SVNSSHConnector.java:149)
          	at org.tmatesoft.svn.core.internal.io.svn.SVNConnection.open(SVNConnection.java:77)
          	at org.tmatesoft.svn.core.internal.io.svn.SVNRepositoryImpl.openConnection(SVNRepositoryImpl.java:1274)
          	at org.tmatesoft.svn.core.internal.io.svn.SVNRepositoryImpl.testConnection(SVNRepositoryImpl.java:99)
          	at org.tmatesoft.svn.core.io.SVNRepository.getRepositoryUUID(SVNRepository.java:268)
          	at jenkins.scm.impl.subversion.SVNRepositoryView.<init>(SVNRepositoryView.java:92)
          	at jenkins.scm.impl.subversion.SubversionSCMSource.openSession(SubversionSCMSource.java:336)
          	at jenkins.scm.impl.subversion.SubversionSCMSource.retrieve(SubversionSCMSource.java:272)
          Caused: java.io.IOException
          	at jenkins.scm.impl.subversion.SubversionSCMSource.retrieve(SubversionSCMSource.java:278)
          	at jenkins.scm.api.SCMSource.fetch(SCMSource.java:583)
          	at org.jenkinsci.plugins.workflow.multibranch.SCMBinder.create(SCMBinder.java:95)
          	at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:303)
          	at hudson.model.ResourceController.execute(ResourceController.java:97)
          	at hudson.model.Executor.run(Executor.java:429) 

          Thank you for taking a look at this!

          With best regards,
          Tom.

          Tom Ghyselinck added a comment - Hi all, Please note that update to 1.29.1 also causes Subversion Plugin (2.12.1) to fail on  svn+ssh checkouts: org.tmatesoft.svn.core.SVNCancelException: svn: E200015: authentication cancelled at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.cancel(SVNErrorManager.java:39) at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.cancel(SVNErrorManager.java:34) at org.tmatesoft.svn.core.internal.io.svn.SVNSSHConnector.open(SVNSSHConnector.java:149) at org.tmatesoft.svn.core.internal.io.svn.SVNConnection.open(SVNConnection.java:77) at org.tmatesoft.svn.core.internal.io.svn.SVNRepositoryImpl.openConnection(SVNRepositoryImpl.java:1274) at org.tmatesoft.svn.core.internal.io.svn.SVNRepositoryImpl.testConnection(SVNRepositoryImpl.java:99) at org.tmatesoft.svn.core.io.SVNRepository.getRepositoryUUID(SVNRepository.java:268) at jenkins.scm.impl.subversion.SVNRepositoryView.<init>(SVNRepositoryView.java:92) at jenkins.scm.impl.subversion.SubversionSCMSource.openSession(SubversionSCMSource.java:336) at jenkins.scm.impl.subversion.SubversionSCMSource.retrieve(SubversionSCMSource.java:272) Caused: java.io.IOException at jenkins.scm.impl.subversion.SubversionSCMSource.retrieve(SubversionSCMSource.java:278) at jenkins.scm.api.SCMSource.fetch(SCMSource.java:583) at org.jenkinsci.plugins.workflow.multibranch.SCMBinder.create(SCMBinder.java:95) at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:303) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Thank you for taking a look at this! With best regards, Tom.
          Tom Ghyselinck made changes -
          Priority Original: Minor [ 4 ] New: Critical [ 2 ]
          Tom Ghyselinck made changes -
          Assignee New: Ivan Fernandez Calvo [ ifernandezcalvo ]

            ifernandezcalvo Ivan Fernandez Calvo
            notizblock Florian P
            Votes:
            9 Vote for this issue
            Watchers:
            19 Start watching this issue

              Created:
              Updated:
              Resolved: