Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-40092

slave.jar copy via SCP fails in 2.33+

XMLWordPrintable

      After upgrade to 2.34 I got this when trying to launch slave agent over ssh:

      [11/29/16 10:55:03] [SSH] Checking java version of java
      [11/29/16 10:55:04] [SSH] java -version returned 1.8.0_65.
      [11/29/16 10:55:04] [SSH] Starting sftp client.
      [11/29/16 10:55:04] [SSH] SFTP failed. Copying via SCP.
      [11/29/16 10:55:05] [SSH] Copying latest slave.jar...
      ERROR: Unexpected error in launching a slave. This is probably a bug in Jenkins.
      java.lang.NullPointerException
      	at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:1792)
      	at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:1769)
      	at org.apache.commons.io.IOUtils.copy(IOUtils.java:1744)
      	at org.apache.commons.io.IOUtils.toByteArray(IOUtils.java:462)
      	at hudson.plugins.sshslaves.SSHLauncher.copySlaveJarUsingSCP(SSHLauncher.java:1098)
      	at hudson.plugins.sshslaves.SSHLauncher.copySlaveJar(SSHLauncher.java:1059)
      	at hudson.plugins.sshslaves.SSHLauncher.access$300(SSHLauncher.java:137)
      	at hudson.plugins.sshslaves.SSHLauncher$2.call(SSHLauncher.java:723)
      	at hudson.plugins.sshslaves.SSHLauncher$2.call(SSHLauncher.java:706)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      	at java.lang.Thread.run(Thread.java:745)
      [11/29/16 10:55:05] Launch failed - cleaning up connection
      [11/29/16 10:55:05] [SSH] Connection closed.
      

      Full log in attachment.

      After downgrade to 2.31 it works just fine.

      Any ideas?
      I've tried to create new node but it's the same. Not sure where to search for more details

      I'm using ssh and it works:

      [jenkins@master ~]$ ssh -l jenkins slave -v
      OpenSSH_5.3p1, OpenSSL 1.0.0-fips 29 Mar 2010
      debug1: Reading configuration data /etc/ssh/ssh_config
      debug1: Applying options for *
      debug1: Connecting to slave [xxxx] port 22.
      debug1: Connection established.
      debug1: identity file /home/jenkins/.ssh/id_rsa type 1
      debug1: Remote protocol version 2.0, remote software version OpenSSH_5.3
      debug1: match: OpenSSH_5.3 pat OpenSSH*
      debug1: Enabling compatibility mode for protocol 2.0
      debug1: Local version string SSH-2.0-OpenSSH_5.3
      debug1: SSH2_MSG_KEXINIT sent
      debug1: SSH2_MSG_KEXINIT received
      debug1: kex: server->client aes128-ctr hmac-md5 none
      debug1: kex: client->server aes128-ctr hmac-md5 none
      debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
      debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
      debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
      debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
      debug1: Host 'slave' is known and matches the DSA host key.
      debug1: Found key in /home/jenkins/.ssh/known_hosts:13
      debug1: ssh_dss_verify: signature correct
      debug1: SSH2_MSG_NEWKEYS sent
      debug1: expecting SSH2_MSG_NEWKEYS
      debug1: SSH2_MSG_NEWKEYS received
      debug1: SSH2_MSG_SERVICE_REQUEST sent
      debug1: SSH2_MSG_SERVICE_ACCEPT received
      xxxx
      debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
      debug1: Next authentication method: publickey
      debug1: Offering public key: /home/jenkins/.ssh/id_rsa
      debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
      debug1: Next authentication method: password
      jenkins@slave's password:
      debug1: Authentication succeeded (password).
      debug1: channel 0: new [client-session]
      debug1: Requesting no-more-sessions@openssh.com
      debug1: Entering interactive session.
      debug1: Sending environment.
      debug1: Sending env LANG = en_US.UTF-8
      Last login: Tue Nov 29 11:05:09 2016 from master
      

      I'm running jenkins on:
      master:
      Red Hat Enterprise Linux Server release 6.3 (Santiago)
      java version "1.7.0_55"

      slave:
      Red Hat Enterprise Linux Server release 6.6 (Santiago)
      openjdk version "1.8.0_65"

            jglick Jesse Glick
            pchudzik Pawel Chudzik
            Votes:
            4 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated:
              Resolved: