timja / jenkins-gh-issues-poc-06-18

0 stars 0 forks source link

[JENKINS-31370] Jenkins jobs tied to a specific label stuck in queue and Jenkins not making request for new slave creation #7626

Open timja opened 8 years ago

timja commented 8 years ago

I am seeing that some times Jenkins jobs tied to a specific label are stuck in queue for no reason. Per my observations Jenkins is not triggering new slave request for the label.

To be specific Jenkins not making a call to canProvision API ( http://javadoc.jenkins-ci.org/hudson/slaves/Cloud.html#canProvision(hudson.model.Label) ).

I tried below scripts to reset queue but not seeing any difference.
hudson.model.Hudson.getInstance().getQueue().scheduleMaintenance()
jenkins.model.Jenkins.getInstance().getQueue().scheduleMaintenance()

This is observed for both Amazon EC2 plugin and Azure slave plugin with Jenkins version 1.630

Note that if i change the label in template then Jenkins is triggering new slave creation request. Even Jenkins restart is not helping.

To me it looks like some sort of deadlock condition on the label , what could be the possible reasons and is there any work around?


Originally reported by snallami, imported from: Jenkins jobs tied to a specific label stuck in queue and Jenkins not making request for new slave creation
  • status: Open
  • priority: Major
  • resolution: Unresolved
  • imported: 2022/01/10
timja commented 8 years ago

snallami:

I found workaround - I am not sure what is causing this though

1. Check Jenkins threads info , it will be @ /monitoring?part=threads and look for threads with name Computer.threadPoolForRemoting.

2. Force kill by clicking on the red dot in 'kill' column.

Need to find out why some times thread are going into "TIMED_WAITING" state and Jenkins is not responding.