volcano-sh / volcano

A Cloud Native Batch System (Project under CNCF)
https://volcano.sh
Apache License 2.0
4.03k stars 930 forks source link

The differences of PriorityClass between volcano and default scheduler? #3512

Open zhucan opened 2 months ago

zhucan commented 2 months ago

Please provide an in-depth description of the question you have:

for k8s default scheduler: An example use case is for data science workloads. A user may submit a job that they want to be prioritized above other workloads, but do not wish to discard existing work by preempting running pods. The high priority job with preemptionPolicy: Never will be scheduled ahead of other queued pods, as soon as sufficient cluster resources "naturally" become free.

but I don't know clear about the volcano.

What do you think about this question?: if the preemptionPolicy is Never, the high priority jobs will be scheduler always before the low priority jobs or normal jobs?

Environment:

Monokaix commented 2 months ago

The priorityClass in volcano also play a role in scheduling and preemption,and job with higher priority can preempt lower job,and also schedule first before lower priority job,but a little difference is that volcano will also consider job's queue priority.

zhucan commented 2 months ago

so, The high priority job with "preemptionPolicy: Never" will not be scheduled ahead of other queued pods? @Monokaix

Monokaix commented 2 months ago

so, The high priority job with "preemptionPolicy: Never" will not be scheduled ahead of other queued pods? @Monokaix

It depends, queue's order is determined by share value, if a queue has a lower share value, jobs in this queue will schedule first. Refer to https://volcano.sh/zh/docs/v1-8-2/plugins/#drf for more detail.