Load balancing (computing): Difference between revisions

Content deleted Content added
m lc common nouns
Tags: Visual edit Mobile edit Mobile web edit Advanced mobile edit
m lc common nouns
Tags: Visual edit Mobile edit Mobile web edit Advanced mobile edit
Line 99:
* Power of two choices: pick two servers at random and choose the better of the two options.<ref>{{cite web |title=NGINX and the "Power of Two Choices" Load-Balancing Algorithm |url=https://www.nginx.com/blog/nginx-power-of-two-choices-load-balancing-algorithm/ |website=nginx.com |archive-url=https://web.archive.org/web/20191212194243/https://www.nginx.com/blog/nginx-power-of-two-choices-load-balancing-algorithm/ |archive-date=2019-12-12 |date=2018-11-12}}</ref><ref>{{cite web |title=Test Driving "Power of Two Random Choices" Load Balancing |url=https://www.haproxy.com/blog/power-of-two-load-balancing/ |website=haproxy.com |archive-url=https://web.archive.org/web/20190215173140/https://www.haproxy.com/blog/power-of-two-load-balancing/ |archive-date=2019-02-15 |date=2019-02-15}}</ref>
 
===Master-Workerworker Schemescheme===
[[Master/slave (technology)|Master-Workerworker]] schemes are among the simplest dynamic load balancing algorithms. A master distributes the workload to all workers (also sometimes referred to as "slaves"). Initially, all workers are idle and report this to the master. The master answers worker requests and distributes the tasks to them. When he has no more tasks to give, he informs the workers so that they stop asking for tasks.
 
The advantage of this system is that it distributes the burden very fairly. In fact, if one does not take into account the time needed for the assignment, the execution time would be comparable to the prefix sum seen above.
 
The problem with this algorithm is that it has difficulty adapting to a large number of processors because of the high amount of necessary communications. This lack of [[scalability]] makes it quickly inoperable in very large servers or very large parallel computers. The master acts as a [[Bottleneck (software)|bottleneck]].
[[File:Master-Worker_and_bottleneck.png|thumb|Master-Workerworker and bottleneck]]
 
However, the quality of the algorithm can be greatly improved by replacing the master with a task list that can be used by different processors. Although this algorithm is a little more difficult to implement, it promises much better scalability, although still insufficient for very large computing centers.