Skip to content

Commit 63a3b2e

Browse files
author
abregman
committed
More AWS questions
Created also the file for Grafana questions.
1 parent ed45cd1 commit 63a3b2e

8 files changed

+205
-7
lines changed

README.md

Lines changed: 32 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
:information_source:  This repo contains questions and exercises on various technical topics, sometimes related to DevOps and SRE
44

5-
:bar_chart:  There are currently **1999** exercises and questions
5+
:bar_chart:  There are currently **2112** exercises and questions
66

77
:books:  To learn more about DevOps and SRE, check the resources in [devops-resources](https://github.com/bregman-arie/devops-resources) repository
88

@@ -527,10 +527,6 @@ HTTP Strict Transport Security is a web server directive that informs user agent
527527
Read more [here](https://www.globalsign.com/en/blog/what-is-hsts-and-how-do-i-use-it#:~:text=HTTP%20Strict%20Transport%20Security%20(HSTS,and%20back%20to%20the%20browser.)
528528
</b></details>
529529

530-
<details>
531-
<summary>What is the difference if any between SSL and TLS?</summary><br><b>
532-
</b></details>
533-
534530
#### Network - Misc
535531

536532
<details>
@@ -5913,6 +5909,7 @@ Platform teams in organisations that wish to offer developers additional tools t
59135909

59145910
<details>
59155911
<summary>List some Cloud Run for Anthos use cases</summary><br><b>
5912+
59165913
As it does not support stateful applications or sticky sessions, it is suitable for running stateless applications such as:
59175914

59185915
* Machine learning model predictions e.g Tensorflow serving containers
@@ -7219,6 +7216,8 @@ Yes, you can use DNS for performing load balancing.
72197216
<summary>What is DNS load balancing? What its advantages? When would you use it?</summary><br><b>
72207217
</b></details>
72217218

7219+
#### Load Balancers - Sticky Sessions
7220+
72227221
<details>
72237222
<summary>What are sticky sessions? What are their pros and cons?</summary><br><b>
72247223

@@ -7231,6 +7230,34 @@ Pros:
72317230
* Ensures in-proc sessions are not lost when a new request is created
72327231
</b></details>
72337232

7233+
<details>
7234+
<summary>Name one use case for using sticky sessions</summary><br><b>
7235+
7236+
You would like to make sure the user doesn't lose the current session data.
7237+
</b></details>
7238+
7239+
<details>
7240+
<summary>What sticky sessions use for enabling the "stickiness"?</summary><br><b>
7241+
7242+
Cookies. There are application based cookies and duration based cookies.
7243+
</b></details>
7244+
7245+
<details>
7246+
<summary>Explain application-based cookies</summary><br><b>
7247+
7248+
* Generated by the application and/or the load balancer
7249+
* Usually allows to include custom data
7250+
</b></details>
7251+
7252+
<details>
7253+
<summary>Explain duration-based cookies</summary><br><b>
7254+
7255+
* Generated by the load balancer
7256+
* Session is not sticky anymore once the duration elapsed
7257+
</b></details>
7258+
7259+
#### Load Balancers - Load Balancing Algorithms
7260+
72347261
<details>
72357262
<summary>Explain each of the following load balancing techniques
72367263

exercises/aws/README.md

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ Note: Provided solutions are using the AWS console. It's recommended you'll use
3737
|--------|--------|------|----|----|
3838
| Application Load Balancer | ELB, ALB | [Exercise](app_load_balancer.md) | [Solution](solutions/app_load_balancer.md) | Easy |
3939
| Multiple Target Groups | ELB, ALB | [Exercise](alb_multiple_target_groups.md) | [Solution](solutions/alb_multiple_target_groups.md) | Easy |
40+
| Network Load Balancer | ELB, NLB | [Exercise](network_load_balancer.md) | [Solution](solutions/network_load_balancer.md) | Easy |
4041

4142
#### AWS - Lambda
4243

@@ -1110,6 +1111,14 @@ Application Load Balancer (ALB).
11101111
True.
11111112
</b></details>
11121113

1114+
<details>
1115+
<summary>What are some use cases for using Gateway Load Balancer?</summary><br><b>
1116+
1117+
* Intrusion Detection
1118+
* Firewall
1119+
* Payload manipulation
1120+
</b></details>
1121+
11131122
<details>
11141123
<summary>Explain "health checks" in the context of AWS ELB</summary><br><b>
11151124

@@ -1157,12 +1166,94 @@ Application Load Balancer (routing based on different endpoints + HTTP is used).
11571166
False. ALB can route to multiple target groups.
11581167
</b></details>
11591168

1169+
<details>
1170+
<summary>If you wanted to analyze network traffic, you would use the `____ load balancer`</summary><br><b>
1171+
1172+
Gateway Load Balancer
1173+
</b></details>
1174+
1175+
<details>
1176+
<summary>Who has better latency? Application Load Balancer or Network Load Balancer?</summary><br><b>
1177+
1178+
Network Load Balancer (~100 ms) as ALB has a latency of ~400 ms
1179+
</b></details>
1180+
1181+
<details>
1182+
<summary>True or False? Network load balancer has one static IP per availability zone</summary><br><b>
1183+
1184+
True.
1185+
</b></details>
1186+
1187+
<details>
1188+
<summary>What are the supported target groups for network load balancer?</summary><br><b>
1189+
1190+
* EC2 instance
1191+
* IP addresses
1192+
* Application Load Balancer
1193+
</b></details>
1194+
1195+
<details>
1196+
<summary>What are the supported target groups for gateway load balancer?</summary><br><b>
1197+
1198+
* EC2 instance
1199+
* IP addresses (must be private IPs)
1200+
</b></details>
1201+
1202+
<details>
1203+
<summary>Name one use case for using application load balancer as a target group for network load balancer</summary><br><b>
1204+
1205+
You might want to have a fixed IP address (NLB) and then forward HTTP traffic based on path, query, ... which is then done by ALB
1206+
</b></details>
1207+
1208+
<details>
1209+
<summary>What are some use cases for using Network Load Balancer?</summary><br><b>
1210+
1211+
* TCP, UDP traffic
1212+
* Extreme performance
1213+
</b></details>
1214+
11601215
<details>
11611216
<summary>True or False? Network load balancers operate in layer 4</summary><br><b>
11621217

11631218
True. They forward TCP, UDP traffic.
11641219
</b></details>
11651220

1221+
<details>
1222+
<summary>True or False? It's possible to enable sticky session for network load balancer so the same client is always redirected to the same instance</summary><br><b>
1223+
1224+
False. This is only supported in Classic Load Balancer and Application Load Balancer.
1225+
</b></details>
1226+
1227+
<details>
1228+
<summary>Explain Cross Zone Load Balancing</summary><br><b>
1229+
1230+
With cross zone load balancing, traffic distributed evenly across all (registered) instances in all the availability zones.
1231+
</b></details>
1232+
1233+
<details>
1234+
<summary>True or False? For application load balancer, cross zone load balancing is always on and can't be disabled</summary><br><b>
1235+
1236+
True
1237+
</b></details>
1238+
1239+
<details>
1240+
<summary>True or False? For network load balancer, cross zone load balancing is always on and can't be disabled </summary><br><b>
1241+
1242+
False. It's disabled by default
1243+
</b></details>
1244+
1245+
<details>
1246+
<summary>True or False? In regards to cross zone load balancing, AWS charges you for inter AZ data in network load balancer but no in application load balancer</summary><br><b>
1247+
1248+
False. It charges fir inter AZ data in network load balancer, but not in application load balancer
1249+
</b></details>
1250+
1251+
<details>
1252+
<summary>True or False? Both ALB and NLB support multiple listeners with multiple SSL certificates </summary><br><b>
1253+
1254+
True
1255+
</b></details>
1256+
11661257
#### AWS Security
11671258

11681259
<details>
@@ -2180,3 +2271,12 @@ Security group isn't attached to your EFS or it lacks a rule to allow NFS traffi
21802271
2. Copy the snapshot and mark the "Encrypt" option
21812272
3. Create a new EBS volume out of the encrypted snapshot
21822273
</b></details>
2274+
2275+
<details>
2276+
<summary>You've created a network load balancer but it doesn't work (you can't reach your app on your EC2 instance). What might be a possible reason?</summary><br><b>
2277+
2278+
Missing security group or misconfigured one.
2279+
For example, if you go to your instances in the AWS console you might see that the instances under your NLB are in "unhealthy status" and if you didn't create a dedicated security group for your NLB, that means that the security group used is the one attached to the EC2 instances.
2280+
2281+
Go to the security group of your instance(s) and enable the traffic that NLB should forward (e.g. TCP on port 80).
2282+
</b></details>

exercises/aws/alb_multiple_target_groups.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@ One EC2 instance with a simple web application that shows the web page with the
1111
1. healthy threshold: 3
1212
2. unhealthy threshold: 3
1313
3. interval: 10 seconds
14-
2. Create another target group
14+
2. Create another target group for the third instance
1515
1. Traffic should be forwarded to this group based on the "/test" path
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
## AWS ELB - Network Load Balancer
2+
3+
### Requirements
4+
5+
Two running EC2 instances
6+
7+
### Objectives
8+
9+
1. Create a network load balancer
10+
1. healthy threshold: 3
11+
2. unhealthy threshold: 3
12+
3. interval: 10 seconds
13+
4. Listener should be using TCP protocol on port 80

exercises/aws/solutions/alb_multiple_target_groups.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ One EC2 instance with a simple web application that shows the web page with the
1111
1. healthy threshold: 3
1212
2. unhealthy threshold: 3
1313
3. interval: 10 seconds
14-
2. Create another target group
14+
2. Create another target group for the third instance
1515
1. Traffic should be forwarded to this group based on the "/test" path
1616

1717
### Solution
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
## AWS ELB - Network Load Balancer
2+
3+
### Requirements
4+
5+
Two running EC2 instances
6+
7+
### Objectives
8+
9+
1. Create a network load balancer
10+
1. healthy threshold: 3
11+
2. unhealthy threshold: 3
12+
3. interval: 10 seconds
13+
4. Listener should be using TCP protocol on port 80
14+
15+
### Solution
16+
17+
#### Console
18+
19+
1. Go to EC2 service
20+
2. Click in the left side menu on "Load balancers" under "Load balancing"
21+
3. Click on "Create load balancer"
22+
4. Choose "Network Load Balancer"
23+
5. Insert a name for the LB
24+
6. Choose AZs where you want the LB to operate
25+
7. Choose a security group
26+
8. Under "Listeners and routing" click on "Create target group" and choose "Instances"
27+
1. Provide a name for the target group
28+
2. Set healthy threshold to 3
29+
3. Set unhealthy threshold to 3
30+
4. Set interval to 10 seconds
31+
5. Set protocol to TCP and port to 80
32+
6. Click on "Next" and choose two instances you have
33+
7. Click on "Create target group"
34+
9. Refresh target groups and choose the one you've just created
35+
10. Click on "Create load balancer" and wait for it to be provisioned

exercises/grafana/README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
## Grafana
2+
3+
<details>
4+
<summary>Explain what is Grafana</summary><br><b>
5+
6+
[Grafana Docs](https://grafana.com/docs/grafana/latest/introduction): "Grafana is a complete observability stack that allows you to monitor and analyze metrics, logs and traces. It allows you to query, visualize, alert on and understand your data no matter where it is stored. Create, explore, and share beautiful dashboards with your team and foster a data driven culture."
7+
</b></details>

exercises/security/README.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,23 @@ MAC address flooding attack (CAM table flooding attack) is a type of network att
389389
<summary>What is Cache Poisoned Denial of Service?</summary><br><b>
390390

391391
CPDoS or Cache Poisoned Denial of Service. It poisons the CDN cache. By manipulating certain header requests, the attacker forces the origin server to return a Bad Request error which is stored in the CDN’s cache. Thus, every request that comes after the attack will get an error page.
392+
</b></details>
393+
394+
<details>
395+
<summary>What is the difference if any between SSL and TLS?</summary><br><b>
396+
</b></details>
397+
398+
<details>
399+
<summary>What is SNI (Server Name Indication)?</summary><br><b>
400+
401+
[Wikipedia](https://en.wikipedia.org/wiki/Server_Name_Indication): "an extension to the Transport Layer Security (TLS) computer networking protocol by which a client indicates which hostname it is attempting to connect to at the start of the handshaking process"
402+
</b></details>
403+
404+
<details>
405+
<summary>What benefits SNI introduces?</summary><br><b>
392406

407+
SNI allows a single server to serve multiple certificates using the same IP and port.<br>
408+
Practically this means that a single IP can server multiple web services/pages, each using a different certificate.
393409
</b></details>
394410

395411
#### Security - Threats

0 commit comments

Comments
 (0)