jenkinsci / jenkinsci/durable-task-plugin

[JENKINS-41482] Pipeline bat step hangs (after restart)

Open
#376 19 comments 0 reactions 0 assignees View on GitHub
component:durable-task-plugin imported-jira-issue priority:critical resolution:unresolved
Dominant language
Java
Stars
30
Forks
101
PR merge metrics
No merged PRs in 30d

Description

Pipeline jobs occasionally hang on bat steps. This seems similar to JENKINS-34150">JENKINS-34150 but we are using durable-task 1.12 which has the fix for that.

Thread dump from the job (after 18 hours):

Thread #26

at DSL.bat(awaiting process completion in C:\j\w\\@​tmp\durable-56b1eae1 on )
at WorkflowScript.run(WorkflowScript:349)
at DSL.withEnv(Native Method)
at WorkflowScript.run(WorkflowScript:242)
at DSL.stage(Native Method)
at WorkflowScript.run(WorkflowScript:156)
at DSL.node(running on )
at WorkflowScript.run(WorkflowScript:34)

The bat step is running a batch file:

cmd /c call test.bat ....


which in turn is running a python script which (in this case) is throwing an exception (I can see from inspecting log files on the slave). Looking on the slave the "durable-56b1eae1" folder is present with jenkins-log.txt, jenkins-main.bat and jenkins-wrap.bat inside of it. There is no sign of the batch process on the slave so I presume that it has completed. The build continues to occupy a slot on the executor. There are also several flyweight tasks from the matrix plugin on the same slave.

Please let me know if there is anything else I can do to help diagnose this.

---
Originally reported by rg, imported from: Pipeline bat step hangs (after restart)


  • status: Open
  • priority: Critical
  • component(s): durable-task-plugin
  • label(s): triaged-2018-11, windows
  • resolution: Unresolved
  • votes: 3
  • watchers: 5
  • imported: 2025-12-09

Raw content of original issue

Pipeline jobs occasionally hang on bat steps. This seems similar to JENKINS-34150 but we are using durable-task 1.12 which has the fix for that.

Thread dump from the job (after 18 hours):



Thread #26

at DSL.bat(awaiting process completion in C:\j\w\<folder>\<job>@tmp\durable-56b1eae1 on <slave>)
at WorkflowScript.run(WorkflowScript:349)
at DSL.withEnv(Native Method)
at WorkflowScript.run(WorkflowScript:242)
at DSL.stage(Native Method)
at WorkflowScript.run(WorkflowScript:156)
at DSL.node(running on <slave>)
at WorkflowScript.run(WorkflowScript:34)

The bat step is running a batch file:



cmd /c call test.bat ....



which in turn is running a python script which (in this case) is throwing an exception (I can see from inspecting log files on the slave). Looking on the slave the "durable-56b1eae1" folder is present with jenkins-log.txt, jenkins-main.bat and jenkins-wrap.bat inside of it. There is no sign of the batch process on the slave so I presume that it has completed. The build continues to occupy a slot on the executor. There are also several flyweight tasks from the matrix plugin on the same slave.

Please let me know if there is anything else I can do to help diagnose this.

environment

```
jenkins 2.19.4

durable-task 1.12

Linux server

Windows slave

java 1.8.0_51
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.