-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Overcommit due to max flow priority over min cost by solver #71
Comments
Hi @pratikmeher44, I'm not sure I follow your argument about giving max-flow higher priority. Max-flow on an arc is a hard constraint -- the flow on an arc cannot exceed it, even if the alternatives lead to a higher-cost solution. The only situation in which the solver "chooses" between pushing more flow on an arc vs. pushing flow on another arc is when the arcs have identical cost; if they don't, the solver will always saturate the lower-cost arc first. On the graph level, it is true that the solver "prioritises" max-flow in the sense that any solution to min-cost, max-flow (MCMF) must be a max-flow. The solver's task is to find a minimum-cost max-flow solution; it can never return a solution that isn't a max-flow solution over the graph. However, I don't believe that solving your problem requires solver changes. Instead, you'll want to adopt the cost model so that the cumulative resource demands on all incoming arcs into a machine do not exceed the machine capacity. The solver can push flow up to the capacity of any incoming arc at the same time, so the cost model has to anticipate that the arcs may all be used. Alternatively, if you support preemption, you can resolve the overcommit situation after the fact by evicting low-priority tasks, but since it sounds like you're referring to a Kubernetes/Poseidon setting, that option may not be available to you (I don't think Kubernetes supports preemption yet?). |
We ran some tests with cpu memory cost model where we observed a scenario in which firmament over commits pod to a resource. After analysing the output flow graph from the solver(CS2), it was found that solver gives max flow more priority than min cost in a situation where it has to make a choice between the two. In that process it over commits pod to a resource and the pod fails with "OutOfcpu" status. If min cost was given higher priority than max flow the overcommit issue could be avoided.
As it is part of solver code implementation, can you please suggest if there is any way to make the solver solve the flow graph giving min cost more priority than max flow.
@ms705 @ICGog
The text was updated successfully, but these errors were encountered: