Skip to content
Discussion options

You must be logged in to vote

update, after some time of debugging, now I have solved it.
I found res.CPUs won't be populated until a task is assigned in v1.16.0 (res.CPUs==0), but this is not the case in v1.14.0. This must be a bug introduced in newer version after v1.14.0. Then I changed the code in shed_resources.go:

	if res.CPUs==0{
		/* do not +1 in this case */
		if a.cpuUse+needRes.Threads(res.CPUs, len(res.GPUs)) > res.CPUs {
			log.Debugf("sched: not scheduling on worker %s for %s; not enough threads, need %d, %d in use, target %d", wid, caller, needRes.Threads(res.CPUs, len(res.GPUs)), a.cpuUse, res.CPUs)
			return false
		}
	} else{
		if a.cpuUse+1+needRes.Threads(res.CPUs, len(res.GPUs)) > res.CPUs {
			lo…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by potato1992
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/archived Archive label, use when closing/locking old discussions.
1 participant