Elastic Load Balancer

  • Elastic Load Balancing automatically distributes your incoming application traffic across multiple targets, such as EC2 instances
  • It monitors the health of registered targets and routes traffic only to the healthy targets.
  • Load Balancer are servers that forward internet traffic to multiple servers.

Benefits of Load Balancer

Using load balancer on top of the application provides various advantages:

  1. Spreads Load: Spreads load across multiple targets.​
  2. Single point DNS: Single point entry for DNS. So exposes only one Public IP.​
  3. High availability: Provides High Availability (HA)​.
  4. Health checks: Helps with Health Checks at particular time interval so it knows when not to send traffic to particular instances​. Health checks enable LB to know if instance it forwards traffic to are available for responding to user requests or not.​
  5. AWS managed: Elastic load balancer is managed load balancer by AWS.
elastic-load-balancer

Types of load balancer in AWS


AWS Elastic Load Balancer comes with 4 types of load balancer viz;

  1. Classic Load Balancer (CLB):
    • This is one of the oldest type of load balancer which originated in year 2009
    • Classic Load Balancer functions at the 4th and 7th layer of the OSI model.
    • Health checks can be applied at TCP or HTTP.
    • Single hostname is available due to LB
     

  2. Classic Load Balancer
  3. Application Load Balancer (ALB):
    • An Application Load Balancer functions at the application layer, the 7th layer of the OSI model.
    • It allows you to route to multiple HTTP applications across machines (i.e. Target Groups).
    • It also allows to load balance multiple applications on the same machine (i.e. Containers).
    • Each target group is used to route requests to one or more registered targets.
  4. Application Load Balancer
    Routing to ALB is based on Target Groups:
    • Routing based on the ‘Path’ in URL
    • abc.com/test, abc.com/ users etc.

    • Routing based on ‘Hostname’ in URL
    • one.abc.com, two.abc.com etc.

    • Routing based on ‘Query strings’ (For dynamic websites using DB at backend).
    • As compared to CLB, we need to configure multiple CLB for multiple applications. But on ALB we can use one LB to multiple applications.

  5. Network Load Balancer (NLB):
    • A Network Load Balancer functions at the 4th layer of the Open Systems Interconnection (OSI) model.
    • It can handle millions of requests per second.

  6. Gateway Load Balancer (GWLB):
    • Gateway Load Balancers enable you to deploy, scale, and manage virtual appliances, such as firewalls, intrusion detection and prevention systems (IDP), and deep packet inspection systems.
Scroll Up