question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Google Compute slaves are disconnected during job on configuration reload

See original GitHub issue
  • Jenkins version - checked on: 2.161 and [LTS] 2.150.1
  • Plugin version - 1.4
  • OS: checked on: arch linux and in docker from image jenkinsci/jenkins:lts

I have running jobs on dynamic slaves provisioned with google compute engine. When I use reload existing configuration then all these dynamic slaves are disconnected and the running jobs will not be finished properly. My simplified configuration of casc yaml looks like this:

jenkins:
  slaveAgentPort: 50000
  agentProtocols:
    - "JNLP4-connect"
  nodes:
  - permanent:
      labelString: "some_slave"
      nodeDescription: 'some node'
      retentionStrategy: always
      mode: NORMAL
      name: "some_slave"
      numExecutors: 4
      remoteFS: "/home/jenkins-slave"
      launcher:
        jnlp:
          workDirSettings:
            disabled: true
            internalDir: remoting
  clouds:
  - computeEngine:
      cloudName: "some-resource"
      configurations:
      - bootDiskAutoDelete: true
        bootDiskSizeGbStr: "50"
        bootDiskSourceImageName: "https://www.googleapis.com/compute/v1/projects/some-resource/global/images/jenkins-image"
        bootDiskSourceImageProject: "some-resource"
        bootDiskType: "https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c/diskTypes/pd-ssd"
        description: ""
        externalAddress: true
        labelString: "some-name"
        launchTimeoutSecondsStr: "120"
        machineType: "https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c/machineTypes/n1-standard-2"
        mode: NORMAL
        namePrefix: "some-name"
        networkConfiguration:
          autofilled:
            network: "https://www.googleapis.com/compute/v1/projects/some-resource/global/networks/some-resource"
            subnetwork: "https://www.googleapis.com/compute/v1/projects/some-resource/regions/some-zone4/subnetworks/some-subnet"
        networkTags: "some-tag"
        numExecutorsStr: "1"
        preemptible: false
        region: "https://www.googleapis.com/compute/v1/projects/some-resource/regions/some-zone4"
        retentionTimeMinutesStr: "2"
        runAsUser: "jenkins"
        serviceAccountEmail: "some-acc@some-resource.iam.gserviceaccount.com"
        useInternalAddress: false
        zone: "https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c"
      credentialsId: "jenkins@some-resource"
      instanceCapStr: "45"
      projectId: "some-resource"
credentials:
  system:
    domainCredentials:
    - credentials:
      - googleRobotPrivateKey:
          projectId: "jenkins@some-resource"
          serviceAccountConfig:
            json:
              prevJsonKeyFile: /var/lib/jenkins/jenkins-some-resource.key

To reproduce error I prepared simple pipeline job:

node('some-name') {
   sh ('sleep 120')
}

When pipeline is on sh sleep then I’m reloading configuration:

Started by user my name
Running in Durability level: MAX_SURVIVABILITY
[Pipeline] node
Still waiting to schedule task
‘some-name-5ani2s’ is offline

Running on some-name-5ani2s in /home/jenkins/.jenkins-slave/workspace/pipe
[Pipeline] {
[Pipeline] sh

+ sleep 120
# here is moment of reloading configuration from page http://jenkins-host/configuration-as-code/
Cannot contact some-name-5ani2s: hudson.remoting.ChannelClosedException: Channel "unknown": Remote call on some-name-5ani2s failed. The channel is closing down or has closed down

Below are all jenkins logs:

Jan 27 19:39:25 mypc jenkins[22120]: INFO: Provisioning node from config com.google.jenkins.plugins.computeengine.InstanceConfiguration@1eab7e13 for excess workload of 1 units of label 'some-name'
Jan 27 19:39:25 mypc jenkins[22120]: Jan 27, 2019 7:39:25 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud availableNodeCapacity
Jan 27 19:39:25 mypc jenkins[22120]: INFO: Found capacity for 45 nodes in cloud some-resource
Jan 27 19:39:27 mypc jenkins[22120]: Sent insert request
Jan 27 19:39:27 mypc jenkins[22120]: Jan 27, 2019 7:39:27 PM com.google.jenkins.plugins.computeengine.ComputeEngineComputerLauncher launch
Jan 27 19:39:27 mypc jenkins[22120]: INFO: Launch will wait 120000 for operation operation-1548614365988-58074e12dc736-6e299853-65f14fa6 to complete...
Jan 27 19:39:27 mypc jenkins[22120]: Jan 27, 2019 7:39:27 PM hudson.slaves.NodeProvisioner$StandardStrategyImpl apply
Jan 27 19:39:27 mypc jenkins[22120]: INFO: Started provisioning some-name-5ani2s from gce-some-resource with 1 executors. Remaining excess workload: 0
Jan 27 19:39:27 mypc jenkins[22120]: Jan 27, 2019 7:39:27 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud$1 call
Jan 27 19:39:27 mypc jenkins[22120]: INFO: Waiting 120000ms for node some-name-5ani2s to connect
Jan 27 19:39:27 mypc jenkins[22120]: Jan 27, 2019 7:39:27 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud$1 call
Jan 27 19:39:27 mypc jenkins[22120]: INFO: 0ms elapsed waiting for node some-name-5ani2s to connect
Jan 27 19:39:32 mypc jenkins[22120]: waiting...
Jan 27 19:39:33 mypc jenkins[22120]: Jan 27, 2019 7:39:33 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:33 mypc jenkins[22120]: INFO: Launching instance: some-name-5ani2s
Jan 27 19:39:40 mypc jenkins[22120]: waiting...
Jan 27 19:39:40 mypc jenkins[22120]: Jan 27, 2019 7:39:40 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:40 mypc jenkins[22120]: INFO: bootstrap
Jan 27 19:39:40 mypc jenkins[22120]: Jan 27, 2019 7:39:40 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:40 mypc jenkins[22120]: INFO: Getting keypair...
Jan 27 19:39:40 mypc jenkins[22120]: Jan 27, 2019 7:39:40 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:40 mypc jenkins[22120]: INFO: Using autogenerated keypair
Jan 27 19:39:40 mypc jenkins[22120]: Jan 27, 2019 7:39:40 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:40 mypc jenkins[22120]: INFO: Authenticating as jenkins
Jan 27 19:39:41 mypc jenkins[22120]: Jan 27, 2019 7:39:41 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:41 mypc jenkins[22120]: INFO: Connecting to 35.204.68.97 on port 22, with timeout 10000.
Jan 27 19:39:48 mypc jenkins[22120]: Jan 27, 2019 7:39:48 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:48 mypc jenkins[22120]: INFO: Connected via SSH.
Jan 27 19:39:49 mypc jenkins[22120]: Jan 27, 2019 7:39:49 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:49 mypc jenkins[22120]: INFO: connect fresh as root
Jan 27 19:39:49 mypc jenkins[22120]: Jan 27, 2019 7:39:49 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:49 mypc jenkins[22120]: INFO: Connecting to 35.204.68.97 on port 22, with timeout 10000.
Jan 27 19:39:49 mypc jenkins[22120]: Jan 27, 2019 7:39:49 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:49 mypc jenkins[22120]: INFO: Connected via SSH.
Jan 27 19:39:49 mypc jenkins[22120]: Jan 27, 2019 7:39:49 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:49 mypc jenkins[22120]: INFO: Copying slave.jar to: /tmp
Jan 27 19:39:50 mypc jenkins[22120]: Jan 27, 2019 7:39:50 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:50 mypc jenkins[22120]: INFO: Verifying: java -fullversion
Jan 27 19:39:51 mypc jenkins[22120]: Jan 27, 2019 7:39:51 PM com.google.jenkins.plugins.computeengine.ComputeEngineCloud log
Jan 27 19:39:51 mypc jenkins[22120]: INFO: Launching Jenkins agent via plugin SSH: java -jar /tmp/slave.jar
Jan 27 19:40:15 mypc jenkins[22120]: Jan 27, 2019 7:40:15 PM hudson.slaves.NodeProvisioner$2 run
Jan 27 19:40:15 mypc jenkins[22120]: INFO: some-name-5ani2s provisioning successfully completed. We have now 3 computer(s)

------ Right now is clicked "Reload existing configuration" from UI http://jenkins-host/configuration-as-code/

Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.cloudName = some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.projectId = some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.credentialsId = jenkins@some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.instanceCapStr = 45
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.namePrefix = some-name
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.region = https://www.googleapis.com/compute/v1/projects/some-resource/regions/some-zone4
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.zone = https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.machineType = https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c/machineTypes/n1-standard-2
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.numExecutorsStr = 1
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.preemptible = false
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.labelString = some-name
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.description = 
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskType = https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c/diskTypes/pd-ssd
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskAutoDelete = true
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskSourceImageName = https://www.googleapis.com/compute/v1/projects/some-resource/global/images/jenkins-image
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskSourceImageProject = some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskSizeGbStr = 50
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.AutofilledNetworkConfiguration.network = https://www.googleapis.com/compute/v1/projects/some-resource/global/networks/some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.AutofilledNetworkConfiguration.subnetwork = https://www.googleapis.com/compute/v1/projects/some-resource/regions/some-zone4/subnetworks/some-subnet
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.networkConfiguration = {autofilled={}}
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.externalAddress = true
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.useInternalAddress = false
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.networkTags = some-tag
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.serviceAccountEmail = some-acc@some-resource.iam.gserviceaccount.com
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.retentionTimeMinutesStr = 2
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.launchTimeoutSecondsStr = 120
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.mode = NORMAL
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.runAsUser = jenkins
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.configurations = [{}]
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class hudson.slaves.DumbSlave.name = some_slave
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class hudson.slaves.DumbSlave.remoteFS = /home/jenkins-slave
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class jenkins.slaves.RemotingWorkDirSettings.disabled = true
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class jenkins.slaves.RemotingWorkDirSettings.internalDir = remoting
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.JNLPLauncher@ec62196.workDirSettings = jenkins.slaves.RemotingWorkDirSettings@6dd9cde9
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class hudson.slaves.DumbSlave.launcher = {jnlp={}}
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].mode = NORMAL
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].numExecutors = 4
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].retentionStrategy = hudson.slaves.RetentionStrategy$Always@4880b95e
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].labelString = some_slave
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].nodeDescription = GCE slave
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.credentials.oauth.GoogleRobotPrivateKeyCredentials.projectId = jenkins@some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.credentials.oauth.JsonServiceAccountConfig.prevJsonKeyFile = /var/lib/jenkins/jenkins-some-resource.key
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.BaseConfigurator createAttribute
Jan 27 19:40:28 mypc jenkins[22120]: WARNING: Can't handle class com.google.jenkins.plugins.credentials.oauth.JsonServiceAccountConfig#jsonKeyFile: type is abstract but not Describable.
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.credentials.oauth.GoogleRobotPrivateKeyCredentials.serviceAccountConfig = {json={}}
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.cloudbees.plugins.credentials.domains.DomainCredentials.credentials = [{googleRobotPrivateKey={}}]
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.model.Hudson@5abac6ff.agentProtocols = [JNLP4-connect]
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.cloudName = some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.projectId = some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.credentialsId = jenkins@some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.instanceCapStr = 45
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.namePrefix = some-name
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.region = https://www.googleapis.com/compute/v1/projects/some-resource/regions/some-zone4
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.zone = https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.machineType = https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c/machineTypes/n1-standard-2
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.numExecutorsStr = 1
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.preemptible = false
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.labelString = some-name
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.description = 
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskType = https://www.googleapis.com/compute/v1/projects/some-resource/zones/some-zone4-c/diskTypes/pd-ssd
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskAutoDelete = true
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskSourceImageName = https://www.googleapis.com/compute/v1/projects/some-resource/global/images/jenkins-image
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskSourceImageProject = some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.bootDiskSizeGbStr = 50
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.AutofilledNetworkConfiguration.network = https://www.googleapis.com/compute/v1/projects/some-resource/global/networks/some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.AutofilledNetworkConfiguration.subnetwork = https://www.googleapis.com/compute/v1/projects/some-resource/regions/some-zone4/subnetworks/some-subnet
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.networkConfiguration = {autofilled={}}
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.externalAddress = true
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.useInternalAddress = false
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.networkTags = some-tag
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.serviceAccountEmail = some-acc@some-resource.iam.gserviceaccount.com
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.retentionTimeMinutesStr = 2
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.launchTimeoutSecondsStr = 120
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.mode = NORMAL
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.InstanceConfiguration.runAsUser = jenkins
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.computeengine.ComputeEngineCloud.configurations = [{}]
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.model.Hudson@5abac6ff.slaveAgentPort = 50000
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class hudson.slaves.DumbSlave.name = some_slave
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class hudson.slaves.DumbSlave.remoteFS = /home/jenkins-slave
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class jenkins.slaves.RemotingWorkDirSettings.disabled = true
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class jenkins.slaves.RemotingWorkDirSettings.internalDir = remoting
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.JNLPLauncher@34c73ed6.workDirSettings = jenkins.slaves.RemotingWorkDirSettings@7b41d681
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class hudson.slaves.DumbSlave.launcher = {jnlp={}}
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].mode = NORMAL
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].numExecutors = 4
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].retentionStrategy = hudson.slaves.RetentionStrategy$Always@55c2556a
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].labelString = some_slave
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.slaves.DumbSlave[some_slave].nodeDescription = GCE slave
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting hudson.model.Hudson@5abac6ff.nodes = [hudson.slaves.DumbSlave[some_slave]]
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.credentials.oauth.GoogleRobotPrivateKeyCredentials.projectId = jenkins@some-resource
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.credentials.oauth.JsonServiceAccountConfig.prevJsonKeyFile = /var/lib/jenkins/jenkins-some-resource.key
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.BaseConfigurator createAttribute
Jan 27 19:40:28 mypc jenkins[22120]: WARNING: Can't handle class com.google.jenkins.plugins.credentials.oauth.JsonServiceAccountConfig#jsonKeyFile: type is abstract but not Describable.
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.google.jenkins.plugins.credentials.oauth.GoogleRobotPrivateKeyCredentials.serviceAccountConfig = {json={}}
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.impl.configurators.DataBoundConfigurator tryConstructor
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting class com.cloudbees.plugins.credentials.domains.DomainCredentials.credentials = [{googleRobotPrivateKey={}}]
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting com.cloudbees.plugins.credentials.SystemCredentialsProvider@23a4a6d6.domainCredentials = [com.cloudbees.plugins.credentials.domains.DomainCredentials@471e551e]
Jan 27 19:40:28 mypc jenkins[22120]: Jan 27, 2019 7:40:28 PM io.jenkins.plugins.casc.Attribute setValue
Jan 27 19:40:28 mypc jenkins[22120]: INFO: Setting com.cloudbees.plugins.credentials.GlobalCredentialsConfiguration@3669979b.system = com.cloudbees.plugins.credentials.SystemCredentialsProvider@23a4a6d6

Looks like if I remove from casc configuration jenkins >> nodes, then cloud slaves are not disconnected on reloading configuration. But in production jenkins instance I need both types of slaves, and at this moment I’m only able to reload configuration when there is no jobs running in gcp slaves.

Permanent nodes always remains online after the configuration reload.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:14 (10 by maintainers)

github_iconTop GitHub Comments

2reactions
jetersencommented, Mar 26, 2019

Properly requires some more code for configuring nodes inside JCasC, not overwriting but appending and checking for conflicts and reporting those conflicts

1reaction
devqorecommented, Mar 22, 2019

@robincsmith thank you for reporting to gce 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Jenkins slave went offline during build - Stack Overflow
The slaves goes offline, either because. The jobs running onto it are consuming more RAM than it is having or no memory left....
Read more >
[JIRA] (JENKINS-52922) slave is getting disconnected in the ...
IOException: Backing channel 'JNLP4-connect connection from myip/myip:49165' is disconnected. at hudson.remoting.RemoteInvocationHandler.
Read more >
slave is getting disconnected in the middle of the job
I ran the powershell script which attempted to connect to the Linux server via 443 over and over and over again. I also...
Read more >
Managing Nodes | OpenShift Container Platform 3.11
In rare cases, a router pod might not have a host port configured. In those cases, it is important to follow the recommended...
Read more >
Collection of alerting rules - Awesome Prometheus alerts
alert: PrometheusJobMissing expr: absent(up{job="prometheus"}) for: 0m labels: severity: warning ... Prometheus AlertManager configuration reload failure.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found