You are signed in. Close

You are signed out. Close

Thank you. Your subscription has started. Close

Thank you. You will get an email when a new comic comes out. Close

We could not confirm your payment. If you paid, use the link "Sign in" at the bottom of the page. Close

Something went wrong on our side. Please try again in a moment. Close

Previous episode Server capacity: why a website slows down for everyone at once

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. 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.beforeafterscaling up

    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. 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.the biggest you can rent

    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. 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.+1scaling out

    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. 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.load balancer

    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. 5 Four servers become ten, then forty. The next morning, the line of 9:05 never forms, and every copy has room to spare.40 servers

    Four servers become ten, then forty. The next morning, the line of 9:05 never forms, and every copy has room to spare.

  6. 6 Then Miva writes again. She had made three guesses, and on her fourth, the puzzle started over, empty.MivaMy guessesare gone!

    Then Miva writes again. She had made three guesses, and on her fourth, the puzzle started over, empty.

  7. Go further

    The two ways to grow, and the load balancer, with the names people use.vertical scalinganother name forscaling up: onebigger machinehorizontal scalinganother name forscaling out: morecopies side by sideround robina simple way to shareout: the load balancertakes the servers inturn, one after another

    The two ways to grow, and the load balancer, with the names people use.

Next episode Stateless servers: why a growing website can forget who you are

Share this comic

More comics