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

Batch step running on a node other than the master fails

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Critical Critical
    • None
    • Windows Server 2012 R2 (both master and agent)
      Jenkins 2.138.1
      Pipeline 2.6
      Durable task plugin 1.26
      Pipeline Nodes and Processes 2.22

      Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

      stage('1') {
        node('uitest') {
          bat 'echo something'
        }
      }
      

      After 10 minutes the console output prompts this and the build fails:

      ERROR: script apparently exited with code 0 but asynchronous notification was lost

      In addition the system log gets these exceptions:

      • java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
      • hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from

          [JENKINS-53888] Batch step running on a node other than the master fails

          Yoav Miles created issue -
          Yoav Miles made changes -
          Component/s Original: batch-task-plugin [ 15505 ]
          Yoav Miles made changes -
          Assignee Original: Kohsuke Kawaguchi [ kohsuke ]
          Yoav Miles made changes -
          Description Original: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
          {{  node('uitest') {}}
          {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
          {{    echo "RETURN CODE: $returnCode"}}
          {{  }}}
          {{}}}
          New: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
           {{  node('uitest') {}}
           {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
           {{    echo "RETURN CODE: $returnCode"}}
          {{  }}}
           {{}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from
          Yoav Miles made changes -
          Description Original: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
           {{  node('uitest') {}}
           {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
           {{    echo "RETURN CODE: $returnCode"}}
          {{  }}}
           {{}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from
          New: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
           {{  node('uitest') {}}
           {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
           {{    echo "RETURN CODE: $returnCode"}}
           \{{  }}}
           {{}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from

           

          This behavior is new to 2.5
          Yoav Miles made changes -
          Description Original: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
           {{  node('uitest') {}}
           {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
           {{    echo "RETURN CODE: $returnCode"}}
           \{{  }}}
           {{}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from

           

          This behavior is new to 2.5
          New: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
           {{  node('uitest') {}}
           {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
           {{    echo "RETURN CODE: $returnCode"}}
           {

          {  }

          }}
           {{}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from

           

          This behavior is new to pipeline 2.5
          Yoav Miles made changes -
          Environment Original: Jenkins 2.138.1
          Pipeline 2.5
          New: Jenkins 2.138.1
          Pipeline 2.6
          Yoav Miles made changes -
          Description Original: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
           {{  node('uitest') {}}
           {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
           {{    echo "RETURN CODE: $returnCode"}}
           {

          {  }

          }}
           {{}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from

           

          This behavior is new to pipeline 2.5
          New: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
           {{  node('uitest') {}}
           {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
           {{    echo "RETURN CODE: $returnCode"}}
           {

          {  }

          }}
           {{}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from

           

          This behavior happens since pipeline 2.5
          Yoav Miles made changes -
          Attachment New: log.txt [ 44654 ]
          Yoav Miles made changes -
          Description Original: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           

          {{stage('1') {}}
           {{  node('uitest') {}}
           {{    int returnCode = bat(script: 'echo something', returnStatus: true)}}
           {{    echo "RETURN CODE: $returnCode"}}
           {

          {  }

          }}
           {{}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from

           

          This behavior happens since pipeline 2.5
          New: Running a batch command on another node takes several minutes and then fails. Attached example (all Windows, the echo command won't print):

           


          {{ {{stage('1') {}}}}
          {{{{  node('uitest') {}}}}
          {{{{    bat 'echo something'}}}}
          {{{{ }}}}}
          {{{{}}}}}

          After 10 minutes the console output prompts this and the build fails:
           ERROR: script apparently exited with code 0 but asynchronous notification was lost

          In addition the system log gets these exceptions:
           * java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
           * hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from

           

          This behavior happens since pipeline 2.5

            Unassigned Unassigned
            towel Yoav Miles
            Votes:
            7 Vote for this issue
            Watchers:
            17 Start watching this issue

              Created:
              Updated: