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

Unable to connect to GCE using plugin via ssh

XMLWordPrintable

      I use the plugin to create a slave node on GCE, but the node is always offline.

      I saw the log is below. SSH cannot connect to GCE.

      just before slave jenkins-slave-916wdt gets launched ...
      executing pre-launch scripts ...
      Apr 12, 2019 2:31:47 AM null
      FINEST: Instance jenkins-slave-916wdt is running and ready...
      Apr 12, 2019 2:31:47 AM null
      INFO: Launching instance: jenkins-slave-916wdt
      Apr 12, 2019 2:31:54 AM null
      INFO: bootstrap
      Apr 12, 2019 2:31:54 AM null
      INFO: Getting keypair...
      Apr 12, 2019 2:31:54 AM null
      INFO: Using autogenerated keypair
      Apr 12, 2019 2:31:54 AM null
      INFO: Authenticating as jenkins
      Apr 12, 2019 2:31:55 AM null
      INFO: Connecting to 35.229.250.191 on port 22, with timeout 10000.
      Apr 12, 2019 2:31:56 AM null
      INFO: Failed to connect via ssh: There was a problem while connecting to 35.229.250.191:22
      Apr 12, 2019 2:31:56 AM null
      INFO: Waiting for SSH to come up. Sleeping 5.
      Apr 12, 2019 2:32:01 AM null
      INFO: Connecting to 35.229.250.191 on port 22, with timeout 10000.
      Apr 12, 2019 2:32:01 AM null
      INFO: Failed to connect via ssh: There was a problem while connecting to 35.229.250.191:22
      Apr 12, 2019 2:32:01 AM null
      INFO: Waiting for SSH to come up. Sleeping 5.
      Apr 12, 2019 2:32:06 AM null
      INFO: Connecting to 35.229.250.191 on port 22, with timeout 10000.
      Apr 12, 2019 2:32:07 AM null
      INFO: Connected via SSH.
      Apr 12, 2019 2:32:07 AM null
      INFO: connect fresh as root
      Apr 12, 2019 2:32:07 AM null
      INFO: Connecting to 35.229.250.191 on port 22, with timeout 10000.
      Apr 12, 2019 2:32:07 AM null
      INFO: Connected via SSH.
      Apr 12, 2019 2:32:07 AM null
      INFO: Copying agent.jar to: /tmp
      Apr 12, 2019 2:32:09 AM null
      INFO: Verifying: java -fullversion
      bash: java: command not found
      Apr 12, 2019 2:32:09 AM null
      WARNING: Java is not installed.
      Apr 12, 2019 2:32:09 AM null
      INFO: Launching Jenkins agent via plugin SSH: java -jar /tmp/agent.jar
      Apr 12, 2019 2:32:09 AM null
      WARNING: Error getting exception Exception: java.io.IOException: SSH channel is closed
      

            evanbrown Evan Brown
            shopee Rukeith Tseng
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: