AWS Compute Flashcards
Web service with which you can run virtual server “instances” in the cloud
Amazon Elastic Compute Cloud (Amazon EC2)
Amazon EC2 instance operating systems:
Windows, Linux, or MacOS
EC2 Features
Simple web service interface allows you to obtain and configure capacity with minimal friction
Designed to make web-scale cloud computing easier for developers
Changes the economics of computing by allowing you to pay only for capacity that you use
Provides developers the tools to build failure resilient applications and isolate them from common failure scenarios
Benefits of EC2 include:
Elastic Web-Scale computing – you can increase or decrease capacity within minutes not hours and commission one to thousands of instances simultaneously.
Completely controlled – You have complete control include root access to each instance and can stop and start instances without losing data and using web service APIs.
Flexible Cloud Hosting Services – you can choose from multiple instance types, operating systems, and software packages as well as instances with varying memory, CPU, and storage configurations.
Integrated – EC2 is integrated with most AWS services such as S3, RDS, and VPC to provide a complete, secure solution.
Reliable – EC2 offers a highly reliable environment where replacement instances can be rapidly and predictably commissioned with SLAs of 99.99% for each region.
Secure – EC2 works in conjunction with VPC to provide a secure location with an IP address range you specify and offers Security Groups, Network ACLs, and IPSec VPN features.
Inexpensive – Amazon passes on the financial benefits of scale by charging very low rates and on a capacity consumed basis.
Special type of virtual appliance that is used to create a virtual machine within the Amazon Elastic Compute Cloud (“EC2”)
Amazon Machine Image (AMI)
AMI Features
One or more EBS snapshots, or, for instance-store-backed AMIs, a template for the root volume of the instance (for example, an operating system, an application server, and applications).
Launch permissions that control which AWS accounts can use the AMI to launch instances.
A block device mapping that specifies the volumes to attach to the instance when it’s launched.
3 main categories of AMIs
Community AMIs – free to use, generally you just select the operating system you want.
AWS Marketplace AMIs – pay to use, generally come packaged with additional, licensed software.
My AMIs – AMIs that you create yourself
Data that is supplied by the user at instance launch in the form of a script
User data
Data about your instance that you can use to configure or manage the running instance
Instance metadata
User Data limit
16KB
This tool allows you to query the instance metadata without having to type out the full URI or category names
Instance Metadata Query tool
True or False:
User data and metadata are not encrypted
True
Good for users that want the low cost and flexibility of EC2 without any up-front payment or long-term commitment.
Applications with short term, spiky, or unpredictable workloads that cannot be interrupted.
Applications being developed or tested on EC2 for the first time
EC2 On-demand Pricing
Applications with steady state or predictable usage.
Applications that require reserved capacity.
Users can make up-front payments to reduce their total computing costs even further
Standard Reserved Instances (RIs) provide up to 75% off on-demand price.
Convertible RIs provide up to 54% off on-demand price – provides the capability to change the attributes of the RI if the exchange results in the creation of RIs of equal or greater value.
Scheduled RIs are available to launch within the time window you reserve. This option allows you to match your capacity reservation to a predictable recurring schedule that only requires a fraction of a day, a week, or a month.
EC2 Reserved Instance Pricing
Applications that have flexible start and end times.
Applications that are only feasible at very low compute prices.
Users with an urgent need for a large amount of additional compute capacity.
If Amazon terminate your instances you do not pay, if you terminate you pay for the hour.
EC2 Spot Instance Price
Physical servers dedicated just for your use.
You then have control over which instances are deployed on that host.
Available as On-Demand or with Dedicated Host Reservation.
Useful if you have server-bound software licenses that use metrics like per-core, per-socket, or per-VM.
Each dedicated host can only run one EC2 instance size and type.
Good for regulatory compliance or licensing requirements.
Predictable performance.
Complete isolation.
Most expensive option.
Billing is per host
EC2 Dedicated host
Virtualized instances on hardware just for you.
Also uses physically dedicated EC2 servers.
Does not provide the additional visibility and controls of dedicated hosts (e.g. how instances are placed on a server).
Billing is per instance.
May share hardware with other non-dedicated instances in the same account.
Available as On-Demand, Reserved Instances, and Spot Instances.
Cost additional $2 per hour per region
EC2 Dedicated Instance
A flexible pricing model that provides savings of up to 72% on your AWS compute usage.
This pricing model offers lower prices on Amazon EC2 instances usage, regardless of instance family, size, OS, tenancy, or AWS Region.
Also applies to AWS Fargate and AWS Lambda usage
EC2 Savings Plan
Heavy data usage (e.g. file servers, DWs) Instance Family
Hint: DATA
D Family
Memory optimized Instance Family
Hint: RAM
R Family
General purpose (e.g. app servers) Instance Family
Hint: MAIN
M Family
Compute optimized Instance Family
Hint: COMPUTE
C Family
Graphics intensive workloads Instance Family
Hint: GRAPHICS
G Family
Storage I/O optimized (e.g. NoSQL, DWs) Instance Family
Hint: CHEAP(Think T2)
I Family
FPGA hardware acceleration for applications Instance Family
Hint: FAST
F Family
Lowest cost (e.g. T2-micro) Instance family
Hint: CHEAP (think T2)
T Family
GPU requirements Instance Family
Hint: GPU
P Family
Heavy memory usage (e.g. SAP HANA, Apache Spark) Instance Family
Hint: EXTREME RAM
X Family
High memory and bare metal performance – use for in memory DBs including SAP HANA Instance Family
Hint: HIGH MEMORY
U Family
Fast CPU, high memory, and NVMe-based SSDs – use when high overall performance is required Instance Family
Hint: HIGH COMPUTE & MEMORY
Z Family
Up to 16 TB of HDD-based local storage
Hint: HIGH DISK THROUGHPUT
H Family
Service that provides a highly scalable, high performance container management service that supports Docker containers and allows you to easily run applications on a managed cluster of Amazon EC2 instances
Amazon Elastic Container Service (ECS)
Amazon Elastic Container Service (ECS) Benefits
Eliminates the need for you to install, operate, and scale your own cluster management infrastructure
Using API calls you can launch and stop container-enabled applications, query the complete state of clusters, and access many familiar features like security groups, Elastic Load Balancing, EBS volumes and IAM roles.
Amazon ECS can be used to schedule the placement of containers across clusters based on resource needs and availability requirements.
An Amazon ECS launch type determines the type of infrastructure on which your tasks and services are hosted
Explicitly provision EC2 instances
Responsible for upgrading, patching, care of EC2 pool
Must handle cluster optimization
More granular control over infrastructure
Amazon EC2 ECS Launch Type
Control Plane asks for resources and Fargate automatically provisions
Fargate provisions compute as needed
Fargate handles cluster optimization
Limited control, as infrastructure is automated
Amazon Fargate ECS Launch Type
A managed AWS Docker registry service for storing, managing, and deploying Docker images
Elastic container registry (ECR)
ECR Features:
There is no additional charge for Amazon ECS. You pay for AWS resources (e.g. EC2 instances or EBS volumes) you create to store and run your application.
Amazon ECR is integrated with Amazon EC2 Container Service (ECS).
With Amazon ECR, there are no upfront fees or commitments. You pay only for the amount of data you store in your repositories and data transferred to the Internet.
A serverless computing technology that allows you to run code without provisioning or managing servers
Executes code only when needed and scales automatically
AWS Lambda
Benefits of AWS Lambda
You pay only for the compute time you consume (you pay nothing when your code is not running)
No servers to manage.
Continuous scaling.
Millisecond billing.
Integrates with almost all other AWS services
Primary use cases for AWS Lambda
Data processing.
Real-time file processing.
Real-time stream processing.
Build serverless backends for web, mobile, IOT, and 3rd party API requests.
One of the newest services in the AWS Compute suite of products.
Great for users who do not have deep AWS technical expertise as it makes it very easy to provision compute services
Amazon LightSail
Amazon LightSail Benefits and features
Provides developers compute, storage, and networking capacity and capabilities to deploy and manage websites, web applications, and databases in the cloud
Includes everything you need to launch your project quickly – a virtual machine, SSD-based storage, data transfer, DNS management, and a static IP.
Provides preconfigured virtual private servers (instances) that include everything required to deploy and application or create a database
Underlying infrastructure and operating system is managed by Amazon LightSail.
Best suited to projects that require a few dozen instances or fewer.
Provides a simple management interface.
Good for blogs, websites, web applications, e-commerce etc.
Can deploy load balancers and attach block storage.
Public API
Can connect to each other and other AWS resources through public Internet and private (VPC peering) networking.
Application templates include WordPress, WordPress Multisite, Drupal, Joomla!, Magento, Redmine, LAMP, Nginx (LEMP), MEAN, Node.js, and more.
Amazon LightSail currently supports 6 Linux or Unix-like distributions: Amazon Linux, CentOS, Debian, FreeBSD, OpenSUSE, and Ubuntu, as well as 2 Windows Server versions: 2012 R2 and 2016
Amazon LightSail Limits
20 Amazon LightSail instances, 5 static IPs, 3 DNS zones, 20 TB block storage, 40 databases, and 5 load balancers per account
Up to 20 certificates per calendar year
Instances that are dedicated to running databases
Amazon LightSail Databases
Amazon LightSail Databases Features and Benefits
Can contain multiple user-created databases, and you can access it by using the same tools and applications that you use with a stand-alone database.
Provide an easy, low maintenance way to store your data in the cloud.
Manages a range of maintenance activities and security for your database and its underlying infrastructure.
Automatically backs up your database and allows point in time restore from the past 7 days using the database restore tool.
Amazon LightSail databases support the latest major versions of MySQL. Currently, these versions are 5.6, 5.7, and 8.0 for MySQL.
Amazon LightSail databases are available in Standard and High Availability plans.
High Availability plans add redundancy and durability to your database, by automatically creating standby database in a separate Availability Zone.
Amazon LightSail Pricing
Amazon LightSail is very affordable.
Amazon LightSail plans are billed on an on-demand hourly rate, so you pay only for what you use.
For every Amazon LightSail plan you use, we charge you the fixed hourly price, up to the maximum monthly plan cost.
The fastest and simplest way to get web applications up and running on AWS
Developers simply upload their application code, and the service automatically handles all the details such as resource provisioning, load balancing, auto-scaling, and monitoring.
AWS Elastic Beanstalk
AWS Elastic Beanstalk Features
Elastic Beanstalk is ideal if you have a PHP, Java, Python, Ruby, Node.js, .NET, Go, or Docker web application.
Elastic Beanstalk uses core AWS services such as Amazon EC2, Amazon Elastic Container Service (Amazon ECS), Auto Scaling, and Elastic Load Balancing to easily support applications that need to scale to serve millions of users.
Enables developers, scientists, and engineers to run hundreds of thousands of batch computing jobs easily and efficiently on AWS
AWS Batch
AWS Batch Features and Benefits
Dynamically provisions the optimal quantity and type of compute resources (e.g., CPU or memory optimized instances) based on the volume and specific resource requirements of the batch jobs submitted.
Simply package the code for your batch jobs, specify their dependencies, and submit your batch job using the AWS Management Console, CLIs, or SDKs.
Allows you to specify execution parameters and job dependencies, and facilitates integration with a broad range of popular batch computing workflow engines and languages (e.g., Pegasus WMS, Luigi, and AWS Step Functions).
Efficiently and dynamically provisions and scales Amazon EC2 and Spot Instances based on the requirements of your jobs. AWS Batch provides default job queues and compute environment definitions that enable you to get started quickly.