Computing Flashcards
What are the 2 main AWS container orchestration services?
-AWS Elastic Constainer Service (ECS)
-AWS Elastic Kubernetes Service (EKS)
What are the 2 main compute options on AWS ECS?
-EC2 (Customer managed instances)
-Fargate (Serverless)
What is the AWS service used for storing, managing and deploying container images?
-Elastic Container Registry (ECR)
True or False: ECR is compatible with the Docker Registry HTTP API V2
True
True or False: It is not recommended to run LLM inference on ECS since it lacks GPU Support
False, ECS has GPU support since it can run on any EC2 instance type
Whats the main use case where EKS is the recommended container orchestration solution?
If the cliente already works with Kubernetes and has built it’s systems around it.
True or False: ECR can only replicate repositories within the same region
False, ECR can replicate repositories both to different regions and different accounts
What are the types of accepted ECR repositories?
Public and Private
ECR can be configured to perform security scans of it’s images on which situations?
On Push and, in the case of Enhanced Scanning, Continuous Scanning. Otherwise, scans have to be performed manually.
What are the types of image scanning allowed in ECR?
-Basic Scanning using Common Vulnerabilities and Exposures Databases (CVEs)
-Enhanced Scanning using Amazon Inspector
What kinds of vulnerabilities can ECR Enhanced Scanning detect that Basic Scanning can’t?
Enhanced Scanning can detect OS vulnerabilities and Programming Language vulnerabilities
True or False: The results of the ECR Image Scan ca trigger EventBridge
True
What does the placement engine on ECS do?
It determines which images will be spun in what hardware/instance.
True or False: You can specify placement constraints and task placement strategies as part of your overall scheduling strategy to customize how Amazon ECS places your tasks.
True
What are the ECS Task Placement Strategies?
-Binpack: Places new task in instance with least CPU or Memory available.
-Spread: Distributes new tasks evenly between instances.
-Random: Places new task in random instance.
What are advantages of each ECS task allocation strategy? (Binpack, spread, random)
-Binpack: Useful for running few instances.
-Spread: Good for high availability
-Random: No advantages.
What are the ECS Task Placement Constraints?
Affinity: Places new task on group with a specific atribute (AZ, instance type, etc)
DIstinct Instance: New tasks have to be placed on different container instance (only one container of that image per instance)
Whtas the use case difference between ECS Task Scheduler and ECS Service Scheduler?
Task Scheduler should be used to run on-demand workloads while Service Scheduler should be used to run continuous, long-running applications
True or False: Fargate works with both ECS and EKS
True
Whats the most common way to integrate Secret Manager and SSM with ECS?
Pass secrets and configurations as environment variables to the running docker container
What are the types of ECS task networking?
- none: No connectivity or port mappings
- bridge: Use Docker’s virtual container-based network
- host: bypass Docker and use the underlying host’s network interface
- awsvpc: every task launched gets own ENI and private IP. Default for Fargate.
The types of ECS auto-scaling are _______, based on the value of a pre-defined CloudWatch metric, ________, based on a specific CloudWatch alarm and ________, which happens periodically on a predetermined date/time
-Target Tracking
-Step Scaling
-Scheduled Scaling
True or False: Both Fargate and EC2 launch types on ECS can run in spot instances
True
True or False: An ECS cluster can either only have EC2 tasks or Fargate tasks, not both
False, a single ECS cluster can have tasks of any combination of launch types. A common use case is to have containers running on EC2 and to create more containers for dealing with spikes using Fargate, since they spin up faster
True or false: An ECS task definition is immutable
True
What is a Fargate platform version?
It is a specific runtime environment to be used on the execution of the ECS task, which includes the operating system kernel version and container runtime (Docker daemon) versions.
What are the 3 permission types Fargate receives from IAM?
-Cluster permissions
-Application permissions
-Task housekeeping permissions
What do Fargate cluster permissions govern?
Who can start, stop and describe tasks in a cluster. They work at a cluster level.
What do Fargate application permissions govern?
The permissions the containers executing the ECS task possess to access other AWS resources
What do Fargate task housekeeping permissions govern?
The permissions needed to perform housekeeping activities around a task, such as registering targets on the ELB, accessing ECR for the container image, etc.
True or False: Fargate ephemeral storage is based on EFS
False, it is based on EBS
How much space does each Fargate task receive for ephemeral storage?
10GB plus 4 GB of shared space for sharing data between containers.
If I Have 5 container inside a single Fargate task, how much ephemeral space will each of them have access to?
2GB (10GB /5) plus the 4 GB of shared space.
What is Kubernetes?
Kubernetes is an Open-Source solution for the management, deployment and caling of containerized aplications
True or False: Kubernets employs a master-worker architecture
True
What are the EKS node types?
-Managed Node Groups
-Self-Managed Nodes
-AWS Fargate (No management or nodes required)
What are the difference between EKS Managed Node Groups and Self-Managed Nodes?
Managed Node Groups create and manage nodes (EC2 instances) for you. These nodes are part of an ASG managed by EKS. Self-Managed Nodes are nodes created by you and registered to the EKS cluster and managed by an ASG.
True or False: Both EKS Managed Node Groups and Self-Managed Nodes support both on-demand and spot EC2 instances
True
What are the types of storage accepted by EKS?
-EBS
-EFS
-FSx for Lustre
-FSx for NetApp ONTAP
What is an ecs cluster?
Its a logical grouping of services and tasks
True ro False: When running an ECS cluster on EC2 you pay for the EC2 instances running plus the cluster manager running on ECS
False
What are the types of storage usable by ECS?
-EBS Volume
-EFS File System
-Amazon ECS Ephemeral Instance Store
What are the main existing EC2 instance types?
-R
-C
-M
-I
-G
What is the specialty of the EC2 R instance type?
It’s an instance with more RAM
What is the specialty of the EC2 C instance type?
It’s an instance with more computing power
What is the specialty of the EC2 M instance type?
It’s an instance type that’s balanced
What is the specialty of the EC2 I instance type?
It’s an instance type with more local I/O capacity
What is the specialty of the EC2 G instance type?
It’s an instance type with GPU
What are the EC2 instance placement groups?
-Cluster
-Spread
-Partition
True or False: Once an instance is created inside a placement group it cannot be moved to another one
False, it can be moved as long as you stop it first
What is the EC2 Cluster placement strategy and what are its advantages?
The cluster strategy places instancesin a low latency group inside the same AZ. Its is good if you are executing a job that needs a lot of fast communication between instance.
What is the EC2 Spread placement strategy and what are its advantages?
The Spread strategy involves placing the instances spread through the harware, with a max of 7 instance per AZ. It’s good for increasing availability though spreading the instances on differente hardware and availability zones.
What is the EC2 Partition placement strategy and what are its advantages?
The Partition strategy involves spreading instance within partitions (same racks) inside a single AZ, with up to 7 possible partitions inside a same AZ. It allows up to 100s of instances on the same Group and do not stop working if one of the racks fail.
What are the existing EC2 instance launch types and what characterizes them?
-On demand: Pay as you go
-Spot instances: For transient workloads, must be prepared to lose access to the instance
-Reserved instances: Intances where you get a discount if you pledge to use them for a predetermined time.
-Dedicated instances: No other user will share hardware
-Dedicated host: Control entire physical server, control instance allocation
What are the available durations for EC2 Reserved Instances?
1 or 3 years
What are the existing payment types or Reserved Instances? Do any of them offer benefits?
There is All Upfront Payment, Partial Upfront Payment and No Upfront Payment, with a discount being offered proportional to ow early the payment is made
What is EC2 Graviton?
It’s a spcific type of EC2 processors with best price performance, but cannot be used with Windows
What are the restrictions on EC2 Graviton usage?
It cannot be used with Windows instances
What are the EC2 inculded metrics?
-CPU usage
-Network In/Out
-System Status
-Disk Usage (Only for instance store)
True or False: RAM is one metric that can be monitored by EC2 metrics
False
True or False: When an EC2 instance is Recovered, it keeps the same Public, Private and Elastic IP
True
True or False: If you High Performance Computing needs fast networking on tightly coupled workload you can employ an Elastic Fabric Adapter (EFA), which can increase network up to 100Gbps or, if your application uses Linux, an Elastic Network Adapter, whic is a more efficient version of EFAs for Linux
False, EFA and ENA are flipped
The best performing FSx version for high aperforming computing in EC2 is ____________
FSx for Lustre
The types of EC2 reserved instances that can be created regarding scope are ______________
Regional and Zonal Reserved Instances
EC2 auto-scaling has all ECS sacling strategies plus a differente one. What is this different scaling strategy?
It’s predictive scaling, where EC2 predicts the future load and scales accordingly
True or False: ASG does not support Spot Fleets
False
What is an Autoscaling Life Cycle Hook?
It is an EC2 configuration that you can setup so that certain actions are performed before an instance is in service or is terminated
True or False: Updating an Auto-Scaling AMI means the EC2 instances automatically get spun down and back up with the new AMI
False, you need to manually terminate them or use EC2 Instance Refresh for Auto Scaling
What does EC2 Instance Refresh do?
It recreates all EC2 instances when an ASG Launch Template is updated, always mantaining a minimum percentage of healthy instances online.
What are the types of Health Checks available for EC2 instances?
-EC2 Status Check
-ELB Health Check (HTTP)
-Custom Health Check (You configure)
How does EC2 Spot Instances determine when to vacate instances from customers and when to allocate them?
-The customer sets a Max Spot Price, and while the current Spot price is under that value that instance is considered usable
What are EC2 Spot Fleets?
Spot Fleets are a group of Spot Instances + On-demand instances (optional) that try to meet target capacity within a price constraint, allowing the request of Spot Instances with the lowest price. You can define multiple launch pools each with their own instance type, AZ, etc and the fleet chooses from the most adequate pool.
What are the EC2 Spot Fleet instance allocation strategies?
-lowestPrice: Allocates from the pool with the lowest price
-diversified: Distributed accross all pools
-capacityOptimized: Pool with the optimal capacity for the number of instances
-priceCapacityOptimized (recommended): Pools with the highest capacity available then select the pool with the lowest price
Whats the difference between Passive and Active High-Availability?
-Passive: When there is failover a failure node is activated so the system keeps working
-Active: There are multiple parallel versions of the system working in paarallel
What are the Docker Container Management services on AWS?
-ECS
-EKS
-Fargate
What is AWS AppRunner?
It’s a service that allow you to create web applications based only on your code or container image
The services that allow you to run ECS or EKS anywhere you like, such as on-premise data centers, are called _____________
ECS Anywhere and EKS Anywhere
What do you need installed on your server for ECS Anywhere to work properly?
ECS Container Agent and SSM Agent
What programming languages does AWS Lambda support by default?
-Node.js (Javascript)
-Python
-Java
-C# (.NET Core)
-Golang
-C#/Powershell
-Ruby
The max available Lambda memory is ______
10GB
The /tmp storage space available in AWS Lambda is ________________
10.240 MB
The max size of the accepted AWS Lambda deployment package is _____________
50MB zipped, 250MB unzipped (including layers)
The max container image size for AWS Lambda is _________________
10GB
True or False: If you configure a Lambda Function with a reserved concurrency of 10, that means that there can only be 10 executions of that function at the same time, but those 10 executions are always available to be used by that function, regardless of other Lambda invocations
True
True or False: AWS Lambda deployments made by Code Deploy have all of the default deployment strategies available (Linear, Canary, AllAtOnce)
True
True or False: When an AWS Lambda is triggered by an Async event (Ex: S3 event) it can by default retry the processing 5 times in case of error, after which it stops trying, with the offending message being sent to an SNS DLQ (Optional)
False, Lambda only retries 3 times
Whats AWS Batch
It’s a service that uses container images to process data on batch requests (Similar to processing jobs)
True or False: AWS Batch is serverless, and can run either on AWS Fargate or on EC2 instances (Spot or On-Demand) inside it’s VPC
True
What is AWS Batch Multi-Node Mode? What is it good for?
Its an AWS mode that allows you to run AWS Batch batches on parallel on multiple EC2/ECS instances. It is good for HPC, and works best if you use a Cluster placement strategy.
True or False: AWS Batch Multi-Node Mode works with neither Spot Instances or Fargate
False, it does work with Fargate, but not Spot Instances
Elastic Beanstalk supports which platforms?
-Go
-PHP
-Python
-Ruby
-Java SE
-Java with Tomcat
-Node.js
-NET on Windows Server with IIS
-Packer Server
-Single Container Docker
-Multi Container Docker
-Preconfigured Docker
-Custom Platform
What kind of migration is EBS recommended for?
Replatforms
What are the available architecture deployment modes for EBS?
-Single instance deployment
-LB + ASG
-ASG only
-Worker
True or False: EBS Can be used to perform Blue/Green deployment
True
What is AWS Compute Optimizer?
It is a service that allows you to optimize your workloads by recommending optimal resources
What are the types of supported AWS Compute Optimizer workloads?
-EC2
-EC2 Auto-scaling
-EBS Volumes
-Lambda Functions
True or False: Compute Optimizer can help you optimize you workload by suggesting optimal configurations and right-sizing your workloads
True
True or False: Compute Optimizer needs Cloudwatch Agent installed on your machines to analize their metrics
False, it needs the agent only to analize Memory Utilization metrics
What are the main use cases of Edge Computing?
-Preprocess Data
-ML
-Transcoding media streams
True or False: Snowball Edge Hardware can be optimized either for Compute, Storage or IO
False, only Compute or Storage
True or False: Both Snowball Edge and Snowcone can run EC2 and Lambda using IoT Greengrass, and both can get discounts if their usage is commited to 1 or 3 years
True
To use the Snow Family you need the _________ interface
AWS Ops Hub
True or False: Enabling CPU hyperthreading in EC2 instances can result in increased performance on HPC contexts
False, you actually should disable it if you want increased performance
True or False: EC2 ENAs are plug-and-use, requiring no additional configurations to be used
False, ENA configuration requires reasonable effort
What is one case where the use of Step Scaling is better over the use of Target Tracking on an ASG?
When you need to scale multiple times in quick succession, since there is a small cooldown on scaling when you use target tracking.
What is the Reserved Instance Marketplace?
It is a place where you can sell your AWS Reserved Instance capabilities if you do note need them anymore
What are the predefined instance attributes valid for reserved instances?
-Type
-Tenancy
-OS
-Region
Whats a Convertible Reserved Instance?
It is a type of reserved instance where you can switch some of the instance parameters (Type, Tenancy, Region, OS)
True or False: To use EC2 Hibernation it’s EBS Block must be encrypted
True
True or False: To use EC2 Hibernation the instance RAM must be smaller then 256GB and it must use EBS as its root volume
False, it must be smaller the 150GB
True or False: EC2 Hibernation is not supported for base metal instances
True
True or False: An EC2 instance can only hibernate for 30 days
False, 60 days
For what types of instances is EC2 hubernation enabled?
On-demand, Reserved, Spot
What are the use cases for the Partition placement group?
-HDFS
-Hbase
-Kafka
-Cassandra
When using App Runner to create a service you must connect to either a Bitbucket or Github repository
False, you must connect only if you are creating a service based on code. A service based on image does not need to connect to a repository.
What is AWS Lightsail?
It is a service focused on the creation of websites and web applications.
What are some development stacks compatible with Lightsail?
-LEMP
-LAMP
-SQL Server Express
What are some applications compatible with Lightsail?
-Wordpress
-Magento
-Drupal
What is the EBS Worker Environment?
It is an environment where you send messagges to SQS and the EBS resources scale based on the number of messages on the queue
True or False: It is common to separate ELB applications in 2 tiers, one web tier (EC@ + ELB) and one worker tier (SQS + EC2)
True