Least connections with a weight for each server. The balancer divides each server's count of requests in progress by its weight and picks the lowest, so a bigger server is trusted with more at once. It combines what weighted round robin knows in advance with what least connections sees as it runs. Below, compare it with both on the same traffic.
The three servers drawn are one of your 2 groups of one big and two small servers, and each dot stands for 100 real requests. A bigger server has more workers, as a bigger machine has more cores. "In progress" under the balancer is what least connections compares. Switching the algorithm restarts the run with exactly the same requests.
Busiest hour vs the daily average. The book's estimate uses 2x.
Measured by load testing. A big server handles its size times this.
Headroom for spikes, slow requests and a failed server. 50 to 70% is common.
1. Average requests per second
2. Peak requests per second
3. Servers needed
4. With the weight matching the size
5. Without the weight
6. If the big server slows to half speed
Steps 1 and 2 are the estimation method from the back-of-the-envelope chapter of Alex Xu's System Design Interview, Vol. 1, including its 2x peak. The rest is standard capacity planning. Step 5 is approximate: once queues form, least connections starts sending the big server more, so the real gap is smaller than shown. The perfect split in step 6 spreads the same traffic over the reduced total capacity.
One makes it the default; the other builds weights into its least connections method.
ipvsadm manual lists wlc as the scheduler that is used by default.least_conn passes each request to "the server with the least number of active connections, taking into account weights of servers." The weights are the same weight= settings used by its default weighted round robin, so switching methods keeps them.The Linux Virtual Server pages are the project's own documentation (the scheduling page is dated 2011; the manual page is a mirrored copy of ipvsadm's). The NGINX page is its official documentation. Quoted phrases are short attributed quotations; everything else is described in our words.