Technology Flashcards
EC2 Pricing Models
On Demand – Typical way, billed by the second of usage
Spot – Take advantage of unused EC2 capacity (Cheapest Option)
Reserved Instances (RI) - Commit to a specific instance type in a specific region for 1 or 3 years
Dedicated Hosts – Pay for a physical server that is fully dedicated to running your instances
Savings Plans – Commit to compute usage for 1 or 3 years, measured by hour
Is EC2 considered serverless?
No, it’s a virtual server running on physical servers
What’s the difference between horizontal and vertical scaling?
Horizontal scaling - Adding or removing servers
Vertical scaling - Increasing technology of existing servers
Elastic load balancing –
automatically distributes traffic across multiple instances
Auto scaling –
Adds or replaces EC2 instances automatically across AZs, based on need and changing demand
EC2 Real world uses:
Deploy a database
Deploy a web app
When to use EC2 On-Demand
You care about low cost without upfront commitment
Apps have unpredictable workloads that can’t be interrupted
Apps are under development
Workloads shorter than a year
When to use EC2 Spot
You are not concerned about start/stop time
Workloads can be interrupted
Your app is only feasible at low prices
Can save up to 90% off On-Demand prices
Pay for the spot price that is in effect at the beginning of each hour
When to use EC2 Reserved Instance (RI)
Your app has a steady state usage for 1 or 3 yr
You can pay money upfront
Your app requires a capacity reservation
Save up to 75% of On Demand prices
Required to sign a contract
Reserve capacity in an availability zone for any duration
You can pay all upfront, partial, or no upfront. All has the biggest discount.
Provides convertible types at 54% discount
When to use EC2 Dedicated Host
You want to bring your own server-bound software licenses
You have regulatory or corporate compliance requirements around tendency model
Save up to 70% off On Demand
Bring existing per-socket, per-core, or per-VM software licenses
No multi-tenancy – meaning the server is not shared with other customers
When to use EC2 Savings Plans
Want lower bill across multiple computing services
Flexibility to change compute services, instance types, OS, or regions
Save up to 72% off On Demand
Not making a commitment to a dedicated host
Savings shared across various compute services, incl. Lambda and Fargate
Does not provide capacity reservation
What do you need to connect to an EC2 instance via SSH?
Keypair
AWS Lambda - Responsibility
You are only responsible for your application code. AWS manages servers, coding environment, and language support.
AWS Fargate
Compute
Serverless compute engine for containers
Lets you manage containers like Docker
Scales automatically
AWS Outposts
Compute
Run cloud services in your datacenter
Supports workloads that need to remain on premises due to latency or data processing needs
Delivers and installs servers in your internal data center
Hybrid experience
Have access to cloud services and APIs to develop apps on-premises
AWS Lightsail
Compute
Great for small projects
Deploy preconfigured apps, like wordpress, with the click of a button
Simple screens for people with no cloud experience
Includes everything you need: SSD-storage, data transfer, DNS management, static IP
Low, predictable monthly fee as low as $3.5/mo
AWS Batch
Compute
Process large workloads in smaller chunks
Run hundreds and thousands of smaller batch processing jobs
Dynamically provision based on volume
Is S3 regional or global?
It’s a regional service, but names must be globally unique
Ways to set security for S3
You can set security at the bucket level or object level using access control lists (ACLs), bucket policies, or access point policies
S3 Standard
General-purpose storage
Stored across multiple AZ
Low latency, high throughput
Durability – 11 9’s
99.99% Availability
Recommended for frequently accessed data
S3 Intelligent Tiering:
Automatically moves data based on access habits
Automatic cost-savings
No retrieval fees
Data stored on multiple AZs
Durability – 11 9’s
99.99% Availability
Recommended for data with unknown or changing access patterns
S3 Standard Infrequent Access (IA)
Accessed less frequently, but requires rapid access
Stored across multiple AZ
Cheaper than S3 standard
Durability – 11 9’s
99.99% Availability
Recommended for
Long-lived data
Infrequently accessed
Millisecond access when needed
S3 One Zone-Infrequent Access:
Similar to S3 Standard IA, but stored in single AZ
Costs 20% less
Data stored in this class can be lost
Durability – 11 9’s
99.95% Availability
Recommended for:
Re-creatable data
Infrequently accessed with millisecond access
Availability and durability not essential
S3 Glacier
Long-term data storage
Retrieval takes longer, 3 options:
1-5 min
3-5 hr
5-12 hr
Data stored across multiple AZs
Durability – 11 9’s
Recommended for:
Long-term backups
Cheap storage option
S3 Glacier Deep Archive
Like S3 glacier but longer access times
Retrieval, 2 options:
12 hr
48 hr
Cheapest of all S3 options
Stored across multiple AZs
Durability – 11 9’s
Recommended for:
Long-term data archival accessed once or twice a year
Retaining data for regulatory compliance
S3 Outposts
Object storage on-premises
Single storage class
Stored across multiple devices and servers
Recommended for:
Data that needs to be kept local
Demanding apps performance needs
S3 Real-World Uses:
Static websites combined with CloudFront
Data archive
Analytics Systems with Redshift or Athena
Mobile Apps
When to use Elastic Block Store (EBS)?
Quickly accessible data
Running a database on an instance
Long-term data storage
Elastic Block Store (EBS)
Storage
Think of it like a flash drive that can be attached or remove from your instances
Data persists while instance is not running
Tied to one AZ
Can only be attached to one instance in the same AZ
EC2 Instance Store
Storage
Local storage that is physically attached to the host computer that cannot be removed
Storage is temporary since data loss occurs when EC2 instance is stopped
Faster and higher I/O speeds
Recommended for:
Temp data
Data replicated across multiple instances
Elastic File System (EFS)
Storage
Serverless network file system that allows you to share files
Only supports linux
More expensive than EBS
Accessible across different AZ in the same region
Recommended for:
Main directories for business-critical apps
Lift-and-shift existing enterprise apps
Storage Gateway
Storage
Hybrid storage system
On-premises and cloud data
Recommended for:
Moving backups to the cloud
Reducing costs for hybrid cloud storage
Low latency access to data
CloudFront
Content Delivery Network (CDN)
CDN that provides global distribution with low latency
Can restrict availability based on location
Speeds up delivery of static and dynamic web content
Uses edge locations to cache content
Real-world uses:
S3 static websites deployed globally
Can stop DDoS attacks
Geo-restrictions based on IP
Amazon Global Accelerator
Content Delivery Network (CDN)
Sends users through the AWS global network when accessing your content, speeding up delivery
Improves latency and availability of single-region apps
60% performance boost
Automatically re-routes traffic to healthy available regional endpoints
Amazon S3 Transfer Acceleration
Content Delivery Network (CDN)
Improves uploads and downloads to S3 buckets
Fast transfer of files across long distances
Uses CloudFront’s globally distributed edge locations
Customers around the world can upload to a central bucket
VPC
Networking
Foundational service that allows you to create secure private networks in the AWS cloud
Private virtual network
Launch EC2 instances
Isolate and protect resources
Spans AZs in a single region
Like a fence around a pizza shop
Subnet
allows you to split the network inside the VPC. This is where you launch your resources like EC2 instances.
Network ACL (NACL)
uses ACLs to ensure the proper traffic is allowed into the subnet
Router and route table
define where network traffic is routed
Internet gateway
allows public traffic into the internet from a VPC
VPC Peering
Allows you to connect 2 VPCs together and facilitates the transfer of data in a secure manner
Route 53
Networking
DNS services that routes users to apps
Domain name registration
Performs health checks on AWS resources
Supports hybrid cloud
Direct Connect
Networking
Dedicated physical network connection from on-premises data center to AWS
Travels over private network
Supports hybrid model
Real world uses:
Large datasets that you need to transfer to AWS
Business critical data transfer to AWS
Hybrid model
AWS VPN
Networking
Site-to-site VPN creates a secure connection between your internal networks and AWS VPCs
Similar to direct connect, but travels over public internet
Automatically encrypted
Connects on-premises data center to AWS
Supports hybrid environment
Slightly cheaper than direct connect
Real world uses:
Makes moving apps to the cloud easier
Virtual Private Gateway
is the connector on the AWS side
Customer Gateway
connector on the customer side
Site-to-site VPN
establish the secure connection between internal networks and AWS
What engines does RDS support?
Aurora, Postgres, MySQL, Maria DB, Oracle, SQL Server.
RDS
Relational DB
Easy to launch and manage
Supports popular DB engines: Aurora, Postgres, MySQL, Maria DB, Oracle, SQL Server.
High availability and fault tolerance using multi-AZs
AWS manages the DB with software updates, patching, automated backups, OS maintenance
Launch read replicas across regions in order to provide enhanced performance and durability
Use Case: Migrate an on-premises DB to the cloud
Aurora
Relational DB
Compatible with MySQL and Postgres
5x faster than normal MySQL and 3x faster than normal Postgres
Scales automatically while providing durability and high availability
Managed by RDS
Use Case: Migrate an on-premises Postgres DB to the cloud
DynamoDB
NoSQL DB
Fully managed key-value DB
Serverless
Non-relational
Scales automatically to massive workloads with fast performance
Use Case: NoSQL database fast enough to handle millions of req a sec
Neptune
Graph DB
Supports highly connected datasets like social media networks
Fully managed and serverless
Fast and reliable
Use Case: Process large sets of user profiles and social interactions
ElastiCache
Fully managed in-memory data store
Compatible with Redis and MemCached
Data can be lost because it is stored in memory
High-performance and low latency
Use Case: Alleviate DB load for data that is accessed often
DocumentDB
Document DB
Compatible with MongoDB
Fully managed and serverless
Non-relational
Use Case: Operate MongoDB workloads at scale
Snowball Edge
Migration
Has locally supported services like EC2 and Lambda
Snowmobile
Migration
Largest member and has exabyte-scale data
45 ft long shipping container
Driven and loaded into an AWS server S3
Securely transported
Snowball
Migration
Transfers pentabytes and is cheaper than the internet
Transfer data in and out
Cheaper than the internet
Snowball edge is supports EC2 and Lambda (when offline)
DataSync
Migration
Transfers data online and can be used to replicate cross-region or account
Online data transfer from on-premises to AWS storage services like S3 or EFS
Copy data over Direct Connect or the internet
Copy data between AWS storage services
Replicate cross-region or cross-account
Athena
Analytics
Query service
Analyze S3 data using SQL
Pay per query
Considered serverless
Real world:
Search for data in S3
Redshift
Analytics
Scalable data warehouse solution
Improves speed and efficiency
Handles exabyte-scale data
Real world uses:
Consolidating multiple data sources
Relational database – When you want to run a database that doesn’t require real-time transaction processing
Database Migration Service (DMS)
Helps you to migrate to or within AWS
Migrate on-premises databases
Continuous data replication
Homogeneous and Heterogenous migrations – From oracle to oracle and from oracle to SQL Server
Virtually no downtime
Real world use cases:
Oracle to Aurora MySQL
Oracle to Oracle
RDS Oracle to Aurora MySQL
Glue
Analytics
Preps data for analytics
Extract, transform, and load service (ETL)
Prepare your data and load
Helps you better understand your data
Kinesis
Analytics
Allows you to analyze data and videos in real-time
Supports video, audio, app logs, website clickstreams
And IoT
Real world:
Log analytics
EMR
Analytics
Helps you process large amounts of data
Process big data
Works with Hadoop
Works with big data frameworks like Apache Spark
Data Pipeline
Analytics
Helps you move data between compute and storage services
Move data at specific intervals
Move data based on certain conditions
Sends notifications on success or failure
Rekognition
Machine Learning
Automate image and video analysis
Identify custom labels in images and videos
Face and text detection in images and videos
Real world:
Alfredo making sure toppings on pizza are correct
Comprehend
Machine Learning
Natural language processing service (NLP) that finds relationships within text
Uncover insights and relationships
Analyzes text
Real-world uses:
Social media posts
Polly
Machine Learning
Turns text to speech
Mimics natural human speech
Several voices
Create a custom voice
Real-world uses:
Adding audio to a blog post
SageMaker
Machine Learning
Helps you build, train, and deploy models quickly
Prepare data for models
Train and deploy
Use deep learning AMIs
Real-world uses:
Recommendation engine
Translate
Machine Learning
Provides real-time and batch language translation
Supports many languages
Translates many content formats
Real-world uses:
Add localization to a website or app
Lex
Machine Learning
Helps you build conversational interfaces like chatbots
Recognize speech and understand language
Powers Alexa
Real-world:
Integrate voice into a device, like Alexa
Cloud9
Developer Tools
IDE in web browser
Write and Debug Code
Supports popular programming languages
Real-world uses:
Build serverless app – Write the lambda code directly in your web browser
CodeCommit
Developer Tools
Source control system for private Git repositories
Commit, branch, and merge code
Collab with other software devs
Real-world uses:
Manage versions of your files (similar to GitHub)
CodeBuild
Developer Tools
Allows you to build and test app source code
Compiles and runs tests
Enables continuous integration and delivery (CICD)
Produces build artifacts ready to be deployed
Real-world uses:
Run tests before deploying a new version of an app to production
Code Deploy
Developer Tools
Manages the deployment of code to compute services in the cloud or on premises
Deploy to: EC2, Fargate, Lambda, and on-premises
Maintains app uptime
Real-world uses:
Maintain app uptime when rolling out a new version
CodePipeline
Developer Tools
Automates software release process
Quickly deliver new features and updates
Integrate with CodeBuild to run builds and tests
Integrate with CodeCommit to retrieve source code
Integrate with CodeDeploy to deploy changes
Real-world uses:
Add automation to building, testing, and deployment of your app
X-Ray
Developer Tools
Debug and analyze production apps
Map app components
View requests end to end
Real-world uses:
Trace calls to RDS database
Infrastructure as Code (IaC) -
Write a script to provision AWS resources. The benefit is that you provision resources in a reproducible manner that saves time
CloudFormation
Deployment and Infrastructure
Allows you to provision AWS services using IaC
Works with most AWS services
Create templates
Real-world uses:
Automate the infrastructure provisioning process for EC2 servers
Elastic Beanstalk
Deployment and Infrastructure
Allows you to deploy your web apps and web services to AWS
Orchestration service that provisions resources
Automatically handles deployment
Monitors app health via a health dashboard
Real-world uses:
Quickly deploy a scalable java-based web app to AWS
OpsWorks
Deployment and Infrastructure
Deploy code and manage apps
Manage on-premises servers or EC2 instances in AWS cloud
Works with Chef and Puppet automation platforms
Real-world uses:
Automate software config and infrastructure management for your app
Simple Queue Service (SQS)
Messaging and Integration
Message queueing service that allows you to build loosely coupled systems
Allows component-to-component communication using messages
Multiple components (or producers) can add messages to the queue
Messages are produced in an asynchronous manner
SQS in the real world:
Money transfer app that performs well under a heavy load
Simple Notification Service (SNS)
Messaging and Integration
Send emails and texts
Publish messages to a topic
Subscribers receive messages
Real world:
Send email when CPU usage of EC2 instance goes above 80%. SNS works with cloud watch to send an email.
Simple Email Service (SES)
Messaging and Integration
Send richly formatted HTML emails
Ideal for marketing or professional emails
Real world:
Track open and CTR of a marketing campaign
Loose coupling -
(good thing) Helps reduce the risk of cascading failures between components
Cascading –
One component breaks, which causes another component to break.. Etc.
CloudWatch
Auditing, Monitoring, Logging
Collect metrics, logs, and events
Detect anomalies
Set alarms
Visualize logs
Real world uses:
Provide real-time monitoring on EC2 instance – send notification once it reaches
CloudTrail
Auditing, Monitoring, Logging
Log and retain account activity
Track activity through console, SDK, CLI
Identify which user made changes
Detect unusual account activity
Real world uses:
Track the time a particular event occurred in your account
Things you can track
Username
Event time and name
IP address
Access key
Region
Error code