Section8: High Availability and scaling Flashcards

1
Q

Why use Elastic Load Balancer?

A
  • Its a managed load balancer, AWS takes care of it.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Name 4 types of load balancer on AWS

A

1) Classic Load Balancer(v1 - old generation) 2009
- Supports Http(layer7),Https TCP(layer4),SSL
2) Application Load Balancer (v2 - new generation,Layer7 load balancer) 2016
- Can do routing
- Are great for micro services and container-based applications
- Supports HTTP, HTTPS, WebSocket
3) Network Load Balancer(v2 - new generation,layer 4) 2017
- Support TCP,TLS,UDP
4) Gateway Load Balancer 2020
- Operates at layer 3(Network layer)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is SNI?

A
  • Stands for Server Name Indication.
  • Solves the problem of loading multiple SSL certificates onto one web server.
  • Its a “newer” protocol and requires the client to indicate the hostname of the target server in the initial SSL handshake.
  • The server then find the correct certificate or return the default one.
  • Note:
    - Only works for ALB & NLB,CloudFront
    - Does not work for CLB.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is Connection Draining?

A
  • In CLB it is called Connection Draining but in ALB & NLB it is called Deregistration Delay.
  • Time to complete “in-flight requests” while the instance is de-registering or unhealthy.
  • Stops sending new request to the EC2 instance which is de-registering.
  • Time is set between 1 to 3600 seconds(default:300 seconds)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Things to remember about ASG(Auto scaling groups)?

A
  • Scaling policies can be on CPU, Netowrk or custom metrics.
  • ASG use Launch configurations or Launch Templates
  • To update an ASG, you must provide a new launch configuration/launch template.
  • IAM roles attached to an ASG will get assigned to EC2 instances.
  • ASG are free, you only pay for the resources used.
  • Having instances under the ASG means that if they get terminated for whatever reason, the ASG will automatically create new ones as a replacement. Extras safety.
  • ASG can terminate instances marked as unhealthy by an LG
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Auto Scaling Groups - Dynamic scaling Policies

A

1) Target Tracking Scaling
- Most simple and easy to setup
- Example: I want the average ASG CPU to stay at 40%
2) Simple/Step Scaling
- When a CloudWatch alarm is triggered(example CPU > 70%) then add 2 units
- When a CloudWatch alarm triggered(example CPU < 30%) then remove 1 unit
3) Scheduled Actions
- Example: increase the min capacity to 10 at 5pm on Fridays
4) Predicting scaling
- Continuously forecast making use of machine learning

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Good metrics to scale on for Auto Scaling Group?

A
  • CPUUtilization
  • RequestCounterPerTarget
  • Average Network In/ Out
  • Any custom metric
How well did you know this?
1
Not at all
2
3
4
5
Perfectly