Scalability and High Availability Flashcards
what are the two types of scalability?
There are 2 types: vertical- adding to the same resource from T2 micro to T2 large and horizontal- adding extra new resources- increasing number of instances move from 2 t2 micro to 4 instances of T2 micro
What is a load balancer?
A load balancer is a server that forwards traffic to multiple servers (EC2) downstream.
Why do we need load balancers?
Load balancers spread the load across multiple instances,
They provide a single point of access to our application,
They handle failures of downstream instances,
They perform regular health checks,
They separate public and private traffic,
They provide high availability and perform termination for ssl and https
What are the different types of load balancers?
There are 4 types of load balancers:
1)classic load balancer - available but deprecated,
2) Application Load balancer used for http,https and
WebSocket, layer 7,
3) Network load balancer for tcp, tls and UDP,
4) Gateway load balancer for IP protocol (layer 3)
What is ALB used for?
Application load balancers are layer 7 http and balance application load across multiple machines or multiple tasks on a single machine (containers). They can
How do ALB route traffic to target groups?
ALB uses routing tables that route traffic to target groups:
• Routing based on path in URL (example.com/users & example.com/posts)
• Routing based on hostname in URL (one.example.com & other.example.com)
• Routing based on Query String, Headers
(example.com/users?id=123&order=false
What are the ALB target groups?
Target groups include EC2 instances(http), ECS tasks(http),lambda functions(http) and IP addresses(private IP only)
How are health checks performed on target groups?
Health checks are performed at the target group level.
How many target groups can the ALB route to?
ALB can route to multiple target groups based on the routing table criteria.
Does the ALB target grp see the client ID?
No, the ALB itself has a fixed name e.g. xxx.region.elb.amazonwas.com and the target group only sees the ALB id and not the client id, the client id, is inserted into the header( x-forwarded-for) and similarly for the port (x-forwarded-port) and the protocol (x-forwarded-proto).
What is a network load balancer?
An NLB is a layer 4 load balancer that routes TCP and UDP traffic. it’s high performing, 100ms compared to ALB which is 400ms.
What is the IP for NLB?
NLB has one static IP per AZ and can be assigned an elastic IP. This is different from CLB and ALB as they don’t have a static Ip but instead a static hostname.
What are the NLB target groups?
NLB target groups include EC2 instances, fixed static IP addresses, and ALB.
What is Gateway Load Balancer(GLB)?
GLB is layer 3 and is used for deploying and managing 3rd party virtual appliances. This load balancer detects intrusion, acts as a firewall and deep packet inspection. It analyses the network traffic.
What is GENEVE protocol and what port does it map to?
This is GLB protocol and it maps to port 6081.