SQF does not balance very well
If there are more than one backend having the same min_used, SQF always choose the first one in the list. It would be better if we can use RR to choose one.
Updated by japc over 10 years ago
A better solution, in my opinion, is to start the loop at a random index instead of always at 0. That way the first one with min_used will be a random one.
I attached a patch that does that, it's for lighttp svn trunk (1.5.0) as of 2009-05-14. Am testing it on a production system of ours.
Updated by stbuehler over 10 years ago
- Status changed from New to Invalid
- Patch available set to No
- If your server has some real load, it doesn't matter where you start.
- If your server has no load and only one request from time to time, you want to go it to the same (first) backend, so the other backend has the chance to get swapped out or whatever.
- Changing RR leads to non-equally distribution if one or more backends are down (the backend after the dead ones will get their load additionally)
Also available in: Atom