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

pipeline hangs after executing sh step command

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Major
    • None
    • Fedora 26, Jenkins ver. 2.60.2, java-1.8.0-openjdk

    Description

      Simple pipeline below sporadically hangs after completing last "sh" step. Command already completed and can't be seen in process list, but pipeline is still in running state and won't finish.

      There are 2 nodes "builder" and "runner", which (for testing) were both setup to run on localhost (via ssh). Jenkins did ~15 builds of pipeline below before running into this problem, there are no other jobs/builds.

      I'll try to keep the system in this failed state for couple days, in case anyone has tips what further data would be useful to gather:

      Jenkinsfile:

      node('builder') {
          stage('Build/Fetch') {
      	git ...
      	sh '''curl -O http://file/skt/sktrc
                    curl -O http://file/skt/default.config'''
          }
          stage('Build') {
      	sh '''./skt.py -vv --state --rc sktrc merge
      	      ./skt.py -vv --state --rc sktrc build
      	      ./skt.py -vv --state --rc sktrc publish'''
      	sktrc = readFile 'sktrc'
      	sh '''./skt.py -vv --state --rc sktrc cleanup'''
          }
      }
      
      node('runner') {
          stage('Test/Fetch') {
      	git 'http://git/skt.git'
      	sh '''curl -O http://filejob.xml'''
      	writeFile file: 'sktrc', text: "${sktrc}"
          }
          stage('Test') {
      	sh '''PATH="/home/worker/bin:$PATH" ./skt.py -vv --state --rc sktrc run --wait
      	      ./skt.py -vv --state --rc sktrc cleanup'''
          }
      }
      

      Pipeline threadDump:

      Thread #12
      	at WorkflowScript.run(WorkflowScript:36)
      	at DSL.stage(Native Method)
      	at WorkflowScript.run(WorkflowScript:35)
      	at DSL.node(running on runner_localhost)
      	at WorkflowScript.run(WorkflowScript:29)
      

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              jstancek Jan Stancek
              Votes:
              1 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: