TP4-HA

1. Load Balancers Theory

Definition

A physiacl or a virtual device design to help to balance the load of net accross different web servers

3 types

Application Load Balancer

  • HTTP
  • intellignet decsion
  • advande request routing
  • ex : change the langage

Network Load Balancers

  • TCP
  • extremely performant

Classic Load Balancer

  • use Layer 7 specific feature
  • a bit cheaper

error 504

  • the gateway has time out
  • the application not responding within the idle timeout period
  • trouble shoot the application.
  • Is it the Web Server or DataBase Server ?

Forwarded-For header

If you need the IPV4 address of your end user, look for the X-forwarded-For header For example if you user connect fisrt to an ELB, your EC2 instance will by default know only your ELB IP ; if you use the X-Forwarded-For header, you will know the public IP address of your user

xforwarde

2. Load Balancers And Health Checks Lab

healthcheck

 synthesis

  • Instances monitored by ELB are reported as InService, or OutofService
  • Health Checks check the instance health by talking to it
  • Load Balanced have their own DNS name. You are never given an IP address
  • The ELB FAQ

3. Advanced Load Balancer Theory

sticky sessions

Sticky sessions enable your users to stick to the same EC2 instance It can be usefull if you are storing information locally to that instance

  • in a classic load balancer

    • with no sticky session : each request are routed to the EC2 instance with the smallest load, independtly
    • with sticky session : the user's session is bound to a specific EC2 instances ; thus all request during a session are sent to the same instance
  • in a Application Load Balancers

    • with sticky session : the traffic will be sent at the target group level

cross zone load balancing

Cross Zone Load Balancer enables you to load balance across multiple availability zones

with cross zone

highly-available

without cross zone

nocz

path patterns

Path patterns allow you to direct traffic to different EC2 instances based on the url contained in the request

Eg : if you want to redirect user ta a specific EC2 instance if they want an image to the following url : url/image

pathpattern


Ce site est propulsé par:

  • unofficial javascript logo
  • react atom logo
  • gatsbyjs logo
  • markdown logo

©2020 - SDLDonfred Digital