Skip to content
BENIBIX Learn

Proxies and Load Balancers

Level 5 · Locked lines and go-betweens

What a proxy server does when it sends your requests on. How a load balancer shares out visitors to many servers at one address.

Course contentsLesson 13 of 13

After this lesson you can

  • Say what a proxy server hides
  • Explain what a load balancer spreads out
  • Say why a health check matters

11 mincovers 2 glossary entries

Worth reading first: HTTPS and TLS Encryption

What the servers in the middle do

Some servers stand in the middle and pass traffic along. A proxy server sends your requests on for you, so the sites you visit see the proxy, not you. A load balancer stands in front of many servers and hands each visitor to one of them. Both sit between the asker and the answer.

A proxy server acts for the people behind it. A school or office often sends all web traffic through one. It can block some sites, keep copies of popular pages and log what was visited. To the outside world, every request seems to come from the proxy's one address.

A proxy is not a lock. It hides your address from the site, but the proxy itself can see everything you send that is not inside HTTPS. Choose one you trust, or it becomes the stranger in the middle that HTTPS was meant to keep out.

A load balancer acts for the servers behind it. Visitors reach one address, and the load balancer picks a server for each request. The simplest way is to take turns. Smarter ways send the next visitor to the server with the least work in hand.

That makes a site both bigger and harder to break. Three servers can answer three times the visitors. And if one dies, the others carry on. The load balancer sends a small test request to each server every few seconds, called a health check, and stops using any that fail it.

The two face opposite ways. A proxy serves a group of users going out to many sites. A load balancer serves one site and the many users coming in to it. A server that stands in front of your own site is a close cousin of the load balancer.

A common mistake is to add a load balancer with no health check. It keeps sending a third of the visitors to a server that has crashed. Those visitors see errors while the other two servers sit half idle. The health check is the part that makes the extra servers worth having.

A proxy speaks for the users behind it. A load balancer speaks for the servers behind it.

Worked example

A ticket site on sale day

A concert sells out every year, and the one server falls over at 9 a.m. This year the team puts a load balancer in front of four servers.

At 9 a.m., 20,000 people arrive in one minute. Each server takes about a quarter. One crashes at 9:03, the health check drops it within 10 seconds, and the other three carry on.

The words for this lesson2

Check yourself

What does a load balancer do?

Finished this lesson?

Marking it complete also marks its 2 glossary entries learned, which updates your roadmap and your saved page. 0 are already marked.