What happens when a website goes viral: how a site keeps up with millions of visitors
Load balancers: why many small servers beat one big one
A website goes down under a big crowd. The first fix most people think of is one bigger server. It works for a while. Big websites do the opposite.
-
1
You rent a bigger server, with more processors and more memory, and move your website onto it. Making one machine bigger is called scaling up, and the next morning it holds the 9:05 crowd.
-
2
But each size up costs more, and even the biggest machine you can rent has a limit. A crowd has no limit: if Rono's post keeps spreading, it will pass the biggest server too.
-
3
So you go the other way and run many ordinary servers, each one a copy of the same website. That is scaling out: when the crowd grows, you add more copies.
-
4
Players still type one address, though. So you put one machine in front of the copies, a load balancer, which passes each request to one of the servers. The work is shared out, and none of them gets buried.
-
5
Four servers become ten, then forty. The next morning, the line of 9:05 never forms, and every copy has room to spare.
-
6
Then Miva writes again. She had made three guesses, and on her fourth, the puzzle started over, empty.
-
Go further
The two ways to grow, and the load balancer, with the names people use.