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

swarm client 2.1 unable to connect to jenkins instance

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Duplicate
    • Component/s: swarm-plugin
    • Labels:
    • Environment:
      Jenkins 2.7.1 with swarm plugin 2.1
    • Similar Issues:

      Description

      Using Jenkins 2.7.1 with swarm plugin 2.1 and swarm client 2.0, everything works fine. However, using the 2.1 client, the node appears but is offline.

      With swarm client 2.0 (good):

      /usr/bin/java -server -Djava.awt.headless=true -jar /home/vagrant/.jenkins_slave/swarm-client-2.0-jar-with-dependencies.jar -mode exclusive -executors 4 -fsroot /home/vagrant/.jenkins_slave/ -labels android-build-hi-cpu -labels linux -labels dockerengine -labels external -master http://172.28.128.100:8080/ -name linux1 -disableClientsUniqueId
      Discovering Jenkins master
      Jul 13, 2016 6:21:20 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Required credentials not available for BASIC <any realm>@172.28.128.100:8080
      Jul 13, 2016 6:21:20 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Preemptive authentication requested but no default credentials available
      Jul 13, 2016 6:21:20 PM org.apache.commons.httpclient.HttpMethodBase getResponseBody
      WARNING: Going to buffer response body of large or unknown size. Using getResponseBodyAsStream instead is recommended.
      Connecting to http://172.28.128.100:8080/
      Attempting to connect to http://172.28.128.100:8080/ f71a0340-de01-4b29-bc0f-8259db788409 with ID 
      Jul 13, 2016 6:21:20 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Required credentials not available for BASIC <any realm>@172.28.128.100:8080
      Jul 13, 2016 6:21:20 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Preemptive authentication requested but no default credentials available
      Could not obtain CSRF crumb. Response code: 404
      Jul 13, 2016 6:21:20 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Required credentials not available for BASIC <any realm>@172.28.128.100:8080
      Jul 13, 2016 6:21:20 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Preemptive authentication requested but no default credentials available
      Jul 13, 2016 6:21:20 PM hudson.remoting.jnlp.Main createEngine
      INFO: Setting up slave: linux1
      Jul 13, 2016 6:21:20 PM hudson.remoting.jnlp.Main$CuiListener <init>
      INFO: Jenkins agent is running in headless mode.
      Jul 13, 2016 6:21:20 PM hudson.remoting.jnlp.Main$CuiListener status
      INFO: Locating server among [http://172.28.128.100:8080/]
      Jul 13, 2016 6:21:20 PM hudson.remoting.jnlp.Main$CuiListener status
      INFO: Connecting to 172.28.128.100:49536
      Jul 13, 2016 6:21:20 PM hudson.remoting.jnlp.Main$CuiListener status
      INFO: Handshaking
      Jul 13, 2016 6:21:20 PM hudson.remoting.jnlp.Main$CuiListener status
      INFO: Connected
      

      Just changing the client to 2.1 (bad):

      /usr/bin/java -server -Djava.awt.headless=true -jar /home/vagrant/.jenkins_slave/swarm-client-2.1-jar-with-dependencies.jar -mode exclusive -executors 4 -fsroot /home/vagrant/.jenkins_slave/ -labels android-build-hi-cpu -labels linux -labels dockerengine -labels external -master http://172.28.128.100:8080/ -name linux1 -disableClientsUniqueId
      Discovering Jenkins master
      Connecting to http://172.28.128.100:8080/ to configure swarm client.
      Jul 13, 2016 6:26:31 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Required credentials not available for BASIC <any realm>@172.28.128.100:8080
      Jul 13, 2016 6:26:31 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Preemptive authentication requested but no default credentials available
      Jul 13, 2016 6:26:31 PM org.apache.commons.httpclient.HttpMethodBase getResponseBody
      WARNING: Going to buffer response body of large or unknown size. Using getResponseBodyAsStream instead is recommended.
      Connecting to http://172.28.128.100:8080/
      Attempting to connect to http://172.28.128.100:8080/ f71a0340-de01-4b29-bc0f-8259db788409 with ID 
      Jul 13, 2016 6:26:31 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Required credentials not available for BASIC <any realm>@172.28.128.100:8080
      Jul 13, 2016 6:26:31 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Preemptive authentication requested but no default credentials available
      Could not obtain CSRF crumb. Response code: 404
      Jul 13, 2016 6:26:31 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Required credentials not available for BASIC <any realm>@172.28.128.100:8080
      Jul 13, 2016 6:26:31 PM org.apache.commons.httpclient.HttpMethodDirector authenticateHost
      WARNING: Preemptive authentication requested but no default credentials available
      

      at which point it indefinitely hangs. Note that there were no changes to the master, just running a different version of the swarm client.

        Attachments

          Issue Links

            Activity

            Hide
            oleg_nenashev Oleg Nenashev added a comment -

            KK does not maintain this plugin anymore. Moving to unassigned to set the expectation

            Show
            oleg_nenashev Oleg Nenashev added a comment - KK does not maintain this plugin anymore. Moving to unassigned to set the expectation
            Hide
            basil Basil Crow added a comment -

            This looks like a duplicate of JENKINS-25421. The workaround is to enable CSRF on the Jenkins master.

            Show
            basil Basil Crow added a comment - This looks like a duplicate of JENKINS-25421 . The workaround is to enable CSRF on the Jenkins master.
            Hide
            basil Basil Crow added a comment - - edited

            Is this still a bug on recent versions of Jenkins core and Swarm client? I just tried connecting to a Jenkins master (2.150.1) with Swarm client 3.16 both with and without CSRF enabled on the Jenkins master, and things worked just fine.

            Show
            basil Basil Crow added a comment - - edited Is this still a bug on recent versions of Jenkins core and Swarm client? I just tried connecting to a Jenkins master (2.150.1) with Swarm client 3.16 both with and without CSRF enabled on the Jenkins master, and things worked just fine.

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              mcrooney mcrooney
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: