More Related Content More from Amazon Web Services More from Amazon Web Services(20) Awsome Days v4.01. 1© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Technical Essentials
Getting Started on AWS
Version 4.0
2. 2© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Module Layout
Module 1: AWS Introduction and History
Module 2: Infrastructure Services: Amazon EC2, Amazon S3, Amazon
EBS, and Amazon VPC
• Lab 1: Build your VPC and launch a web server
Module 3: Security, Identity, and Access Management: IAM
Module 4: Databases: Amazon DynamoDB and Amazon RDS
• Lab 2: Build your database server and interact with you database using an
application
Module 5: AWS Elasticity and Management Tools: Auto Scaling, Elastic
Load Balancing, Amazon CloudWatch, and AWS Trusted Advisor
• Lab 3: Scale and load balance your application and monitor activity
3. 3© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Module 1
AWS Introduction and History
4. 4© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon History
1994: Jeff Bezos
Incorporated the
Company
1995:
Amazon.com
Launched
Online
Bookstore
2005:
Amazon
Publishing
Launched
2006:
Amazon
Web
Services
(AWS)
Launched
2007:
Kindle
Launched
2011:
Amazon
Fresh
Launched
2012: Amazon
Game Studios
Launched
2013:
Amazon
Art
Launched
2014:
Amazon
Prime
Now
Launched
2015:
Amazon
Home
Services &
Amazon
Echo
Launched
5. 5© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Web Services (AWS)
ComputeMessaging
Mobile
App Services
Database
Networking
Development and
Management Tools
Payments
VPC
On-Demand Workforce
Analytics Content Delivery
Storage
Enable businesses and developers to
use web services to build scalable,
sophisticated applications.
6. 6© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Rapid Pace of Innovation
2009
48
159
722
82
2011 2013 2015
New Features/Services
Launched
7. 7© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Direct
Connect
AWS Elastic Beanstalk
AWS GovCloud
Amazon CloudTrail
Amazon S3
Amazon WorkSpaces
Amazon Kinesis
Amazon
AppStream
Amazon SNS
AWS IAM
Amazon Route 53
Amazon SWF
Amazon Redshift
Amazon Dynamo DB
Amazon CloudSearch
AWS Data
Pipeline
Trusted Advisor
AWS KMS
Amazon Config
Amazon RDS
for Aurora
Amazon WorkDocs
AWS
Directory
Service
AWS CodeCommit
AWS CodePipeline
AWS Service Catalog
Amazon CloudWatch Logs
Amazon EFS
Amazon API
Gateway
Amazon Machine
Learning
AWS Device Farm
AWS Web App Firewall
Amazon Elasticsearch Service
Amazon QuickSight
AWS Import/Export Snowball
RDS for MariaDB
Amazon Inspector
AWS IoT
Amazon EC2 Container
Registry
Amazon
ElastiCache
AWS
CloudFormation
Amazon
Mobile
Analytics
AWS Mobile Hub
AWS Storage Gateway
AWS OpsWorks
AWS Elastic Transcoder
Amazon SES
Amazon EC2
Container Service
Amazon Cognito
AWS CodeDeploy
Glacier* As of 1 February 2016
Amazon WorkMail
AWS Lambda
1,950Services and Features
8. 8© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Customers
Enterprise Customers Startup Customers Public Sector Customers
9. 9© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Six Advantages & Benefits of AWS Cloud Computing
Trade capital expense
for variable expense.
Benefit from massive
economies of scale.
Stop guessing
capacity.
Go global in minutes.
Increase speed and
agility.
Stop spending money on
running and maintaining
data centers.
10. 10
Gartner Magic Quadrant for Cloud Infrastructure as a Service, Worldwide
Gartner “Magic Quadrant for Cloud Infrastructure as a Service, Worldwide,” Lydia Leong, Douglas Toombs, Bob Gill, May 18, 2015. This Magic Quadrant graphic was published by Gartner, Inc. as part of a larger
research note and should be evaluated in the context of the entire report. The Gartner report is available at http://aws.amazon.com/resources/analyst-reports/. Gartner does not endorse any vendor, product or
service depicted in its research publications, and does not advise technology users to select only those vendors with the highest ratings or other designation. Gartner research publications consist of the opinions of
Gartner's research organization and should not be construed as statements of fact. Gartner disclaims all warranties, expressed or implied, with respect to this research, including any warranties of merchantability or
fitness for a particular purpose.
11. 11© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Core Infrastructure and Services
AWS Technical Essentials 3.8 ILT
Security
Network
Security
Network
Security Groups NACLs Access Mgmt
VPCVPC
EC2 “Classic”
“Public
”
ELB
On-Demand
Provision
Traditional Infrastructure Amazon Web Services
Servers
AMI Amazon EC2 InstancesOn-Premises Servers
Security
Security Groups NACLs AWS IAMFirewalls ACLs Administrators
Networking
VPCELBRouter Network Pipeline Switch
Storage
and
Database
RDBMSDAS SAN NAS Amazon
EBS
Amazon
EFS
Amazon
S3
Amazon
RDS
12. 12© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Infrastructure Regions Edge LocationsAvailability Zones
Foundation
Services
Compute
(Virtual, Auto-scaling and
Load Balancing)
Networking
Applications Virtual
Desktops
Collaboration and Sharing
Platform
Services
Caching
Relational
No SQL
Cluster
Computing
Real-time
Data
Workflows
Data
Warehouse
Queuing
Orchestration
App Streaming
Transcoding
Email
Search
Containers
Dev/ops Tools
Resource Templates
Usage Tracking
Monitoring and Logs
Identity
Sync
Mobile Analytics
Notifications
AWS Cloud Computing
Databases Analytics App Services Deployment and
Management
Mobile Services
Storage
(Object, Block and Archive)
13. 13© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Compute Network Storage
Security &
Identity
Applications
AWS Foundation Services
Amazon
EC2
AWS
Lambda
Amazon EC2
Container Service
AWS
Elastic Beanstalk
Elastic Load
Balancing
Amazon
VPC
AWS
Direct
Connect
Amazon
Route 53
Amazon S3
Amazon
CloudFront
Amazon
Elastic File
System
Amazon
Glacier
AWS
Storage
Gateway
AWS
Import/Export
Snowball
AWS Identity and
Access Management
AWS
Directory
Service
AWS Cloud
HSM
AWS KMS
AWS WAF
Amazon
WorkDocs
Amazon
WorkSpaces
Auto Scaling
Amazon
WorkMail
14. 14© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Databases Analytics App Services
Management
Tools
Developer
Tools
Mobile
Services
Internet of
Things
AWS Platform Services
Amazon
RDS
Amazon
DynamoDB
Amazon
ElastiCache
Amazon
Redshift
Amazon
EMR
AWS
Data Pipeline
Amazon
Kinesis
Amazon
Machine
Learning
Amazon
Elasticsearch
Service
Amazon
API Gateway
Amazon
AppStream
Amazon
CloudSearch
Amazon
Elastic
Transcoder
Amazon
SES
Amazon
SQS
Amazon
SWF
Amazon
CloudWatch
AWS
CloudFormation
AWS
CloudTrail
AWS
Config
AWS
OpsWorks
AWS
Service
Catalog
AWS
CodeCommit
AWS
CodeDeploy
AWS
CodePipeline
AWS
Device Farm
Amazon
Mobile
Analytics
Amazon
Cognito
Amazon
SNS
Mobile Hub
AWS IoT
Trusted
Advisor
AWS Database
Migration
Service
AWS
Certificate
Manager
15. 15© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Global Infrastructure
Regions
Geographic locations
Consists of at least two Availability Zones(AZs)
Availability Zones
Clusters of data centers
Isolated from failures in other Availability Zones
16. 16© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Global Infrastructure
17. 17© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Global Infrastructure
At least 2 AZs per region.
Examples:
US East (N. Virginia)
• us-east-1a
• us-east-1b
• us-east-1c
• us-east-1d
• us-east-1e
Asia Pacific (Tokyo)
• ap-northeast-1a
• ap-northeast-1b
• ap-northeast-1c
Note: Conceptual drawing only. The number of Availability Zones (AZ) may vary.
US East (VA)
AZ - A AZ - B
AZ - C AZ - D
AZ - E
Asia Pacific
(Tokyo)
AZ - A AZ - B
AZ - C
18. 18© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Achieving High Availability Using Multi-AZ
Availability
Zone - A
Availability
Zone - B
Availability
Zone - C
Region
19. 19© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Global Infrastructure
50+ AWS Edge Locations:
Local points-of-presence commonly supporting AWS
services like:
Amazon Route 53
Amazon CloudFront
20. 20© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Management
Console Demonstration
21. 21© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Knowledge Check
Q: What is the AWS term for physically distinct groups of data centers
within a region?
True or False: There are more regions than Edge locations.
True or False: AWS owns and maintains the infrastructure required
for application services and you provision and use them as needed.
Q: How do AZs in the same region differ?
Availability Zone (AZ).
False.
True.
Each Availability Zone is isolated, but the Availability Zones in a region are
connected through low-latency links.
22. 22© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Module 2
AWS Infrastructure
23. 23© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Elastic Compute
Cloud (EC2)
24. 24© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Elastic Compute Cloud (EC2)
Resizable compute capacity
Complete control of your computing resources
Reduces the time required to obtain and boot
new server instances to minutesAmazon
EC2
25. 25© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Facts
Scale capacity as your computing requirements change
Pay only for capacity that you actually use
Choose Linux or Windows
Deploy across AWS Regions and Availability Zones for reliability
26. 26© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Launching an Amazon EC2 Instance via the Web
Console
1. Determine the AWS Region in which you want to launch the
Amazon EC2 instance.
2. Launch an Amazon EC2 instance from a pre-configured
Amazon Machine Image (AMI).
3. Choose an instance type based on CPU, memory, storage,
and network requirements.
4. Configure network, IP address, security groups, storage
volume, tags, and key pair.
27. 27© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AMI Details
An AMI includes the following:
A template for the root volume for 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.
28. 28© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Instances and AMIs
Select an AMI based on:
Region
Operating system
Architecture (32-bit or 64-bit)
Launch permissions
Storage for the root device
AMI
Instances
Instance
Launch
instances of any
type
Host computer
Host computer
29. 29© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Instances
OS, Applications,
& Configuration
AMI
Running or
Stopped VM
Instances
AZ
VPC
Region
EBS
S3
EBS
Snapshots
S3 Buckets
EBS EBS EBS EBS EBS
AZ
Instances Instances
30. 30© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EBS vs. Amazon EC2 Instance Store
Amazon EBS
Data stored on an Amazon EBS volume can persist
independently of the life of the instance.
Storage is persistent.
Amazon EC2 Instance Store
Data stored on a local instance store persists only as long as the
instance is alive.
Storage is ephemeral.
31. 31© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AMI Types - Storage for the Root Device
Characteristic Amazon EBS-Backed Amazon Instance Store-Backed
Boot time Usually < 1 minute Usually < 5 minutes
Size limit 16 TiB 10 GiB
Data
persistence
The root volume is deleted when the instance
terminates. Data on any other Amazon EBS volumes
persists after instance termination.
Data on any instance store volumes persists
only during the life of the instance.
Charges Instance usage, Amazon EBS volume usage, and
storing your AMI as an Amazon EBS snapshot.
Instance usage and storing your AMI in
Amazon S3.
Stopped state Can be stopped. Cannot be stopped.
32. 32© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Instance Lifecycle
AMI
pending
Launch
running
terminated
shutting-down
Terminate
Stop
stoppingrebooting
Reboot
Start
Terminate
EBS-backed instances only
stopped
33. 33© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Marketplace – IT Software Optimized for the
Cloud
AWS Marketplace:
Is an online store to discover,
purchase, and deploy IT software on top
of the AWS infrastructure.
Catalog of 2300+ IT software solutions
• Including Paid, BYOL, Open Source, SaaS, &
free to try options
Pre-configured to operate on AWS
• Software checked by AWS for security and
operability
Deploys to AWS environment in minutes
Flexible, usage-based billing models
Software charges billed to AWS account
Includes AWS Test Drive.
https://aws.amazon.com/marketplace
34. 34© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Choosing the Right Amazon EC2 Instance
EC2 instance types are optimized for different use cases and come
in multiple sizes. This allows you to optimally scale resources to
your workload requirements.
AWS uses Intel® Xeon® processors for EC2 instances, providing
customers with high performance and value.
Consider the following when choosing your instances: Core count,
memory size, storage size and type, network performance, and
CPU technologies.
Hurry Up and Go Idle - A larger compute instance can save you time
and money, therefore paying more per hour for a shorter amount of
time can be less expensive.
35. 35© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Get the Intel® Advantage
Intel’s latest 22nm Haswell microarchitecture on new C4 instances,
with custom Intel® Xeon® v3 processors, provides new features:
Haswell microarchitecture has better branch prediction; greater
efficiency at prefetching instructions and data; along with other
improvements that can boost existing applications’ performance
by 30% or more
P state and C state control provides the ability to individually tune
each cores performance and sleep states to improve application
performance
Intel® AVX2.0 instructions can double the floating-point performance
for compute-intensive workloads over Intel® AVX, and provide
additional instructions useful for compression and encryption
36. 36© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Intel® Processor Technologies
Intel® AVX – Get dramatically better performance for highly
parallel HPC workloads such as life science engineering, data
mining, financial analysis, or other technical computing
applications. AVX also enhances image, video, and audio
processing.
Intel® AES-NI – Enhance your security with these new
encryption instructions that reduce the performance penalty
associated with encrypting/decrypting data.
Intel® Turbo Boost Technology – Get more computing
power when you need it with performance that adapts to
spikes in your workload with Intel® Turbo Boost Technology
2.0
37. 37© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Burstable Balanced Compute Memory GPU I/O Storage
AWS Instance Type T2 M4 C4 R3 G2 I2 D2
Intel® processor
Intel® Xeon®
family
Intel® Xeon®
E5-2676 v3
Intel® Xeon®
E5-2666 v3
Intel® Xeon®
E5-2670 v2
Intel® Xeon®
E5-2670
Intel® Xeon®
E5-2670 v2
Intel® Xeon®
E5-2676 v3
Intel® process
technology
22nm Haswell 22nm Haswell 22nm Ivy Bridge 32nm Sandy Bridge 22nm Ivy Bridge 22nm Haswell
Intel® AVX
Intel® AVX2
Intel® Turbo Boost
Storage EBS only EBS only EBS only SSD SSD SSD HDD
EC2 Instances with Intel® Technologies
38. 38© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Current Generation Instances
Instance Family Some Use Cases
General purpose (t2, m4, m3) • Low-traffic websites and web applications
• Small databases and mid-size databases
Compute optimized (c4, c3) • High performance front-end fleets
• Video-encoding
Memory optimized (r3) • High performance databases
• Distributed memory caches
Storage optimized (i2, d2) • Data warehousing
• Log or data-processing applications
GPU instances (g2) • 3D application streaming
• Machine learning
39. 39© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Instance Metadata & User Data
Instance Metadata:
Is data about your instance.
Can be used to configure or manage a running
instance.
Instance User Data:
Can be passed to the instance at launch.
Can be used to perform common automated
configuration tasks.
Runs scripts after the instance starts.
40. 40© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Retrieving Instance Metadata
To view all categories of instance
metadata from within a running
instance, use the following URI:
http://169.254.169.254/latest/meta-
data/
On a Linux instance, you can use:
$ curl http://169.254.169.254/latest/meta-data/
$ GET http://169.254.169.254/latest/meta-data/
All metadata is returned as text
(content type text/plain).
41. 41© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Adding User Data
You can specify user data when launching an
instance.
User data can be:
Linux script – executed by cloud-init
Windows batch or PowerShell scripts – executed by
EC2Config service
User data scripts run once per instance-id by default.
42. 42© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
User Data Example Linux
#!/bin/sh
yum -y install httpd
chkconfig httpd on
/etc/init.d/httpd
start
User data shell scripts must start with the #!
characters and the path to the interpreter you
want to read the script.
Install Apache web server
Enable the web server
Start the web server
43. 43© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
User Data Example Windows
<powershell>
Import-Module ServerManager
Install-WindowsFeature web-server, web-webserver
Install-WindowsFeature web-mgmt-tools
</powershell>
Import the Server Manager module
for Windows PowerShell.
Install IIS
Install Web Management Tools
44. 44© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Retrieving User Data
To retrieve user data,
use the following URI:
http://169.254.169.254/
latest/user-data
On a Linux instance,
you can use:
$ curl
http://169.254.169.254
/latest/user-data/
$ GET
http://169.254.169.254
/latest/user-data/
45. 45© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Purchasing Options
On-Demand
Instances
Pay by the hour.
Reserved
Instances
Purchase at
significant
discount.
Instances are
always available.
1-year to 3-year
terms.
Scheduled
Instances
Purchase a 1-
year RI for a
recurring period
of time.
Spot Instances
Highest bidder
uses instance at a
significant
discount.
Spot blocks
supported.
Dedicated
Hosts
Physical host is
fully dedicated to
run your
instances. Bring
your per-socket,
per-core, or per-
VM software
licenses to reduce
cost.
46. 46© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Storage Services
Amazon S3 and Amazon EBS
47. 47© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Simple Storage Service (S3)
Amazon S3
Storage for the Internet
Natively online, HTTP access
Store and retrieve any amount of data, any
time, from anywhere on the web
Highly scalable, reliable, fast and durable
48. 48© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Facts
Able to store an unlimited number of objects in a bucket
Objects up to 5 TB; no bucket size limit
Designed for 99.999999999% durability and 99.99% availability of
objects over a given year
HTTP/S endpoint to store and retrieve any amount of data, at any
time, from anywhere on the web
Highly scalable, reliable, fast, and inexpensive
Optional server-side encryption using AWS or customer-
managed provided client-side encryption
Access logs for auditing
Provides standards-based REST and SOAP interfaces
49. 49© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Common Use Scenarios
Storage and Backup
Application File Hosting
Media Hosting
Software Delivery
Store AMIs and Snapshots
50. 50© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Pricing
Pay only for what you use
No minimum fee
Prices based on location of your Amazon S3 bucket
Estimate monthly bill using the AWS Simple Monthly Calculator
Pricing is available as:
Storage Pricing
Request Pricing
Data Transfer Pricing: data transferred out of Amazon S3
51. 51© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Concepts
Amazon S3 stores data as objects
within buckets
An object is composed of a file and
optionally any metadata that
describes that file
You can have up to 100 buckets in
each account
You can control access to the
bucket and its objects
Amazon
S3
Bucket
with
Objects
Bucket
Object
52. 52© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Buckets
Organize the Amazon S3 namespace at the highest level.
Identify the account responsible for storage and data transfer
charges.
Play a role in access control.
Serve as the unit of aggregation for usage reporting.
Have globally unique bucket names, regardless of the AWS region
in which they were created.
53. 53© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Object Keys
An object key is the unique identifier for an object in a
bucket.
http://doc.s3.amazonaws.com/2006-03-01/AmazonS3.html
Bucket Object/Key
54. 54© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Security
You can control access to buckets and objects with:
Access Control Lists (ACLs)
Bucket policies
Identity and Access Management (IAM) policies
You can upload or download data to Amazon S3 via SSL
encrypted endpoints.
You can encrypt data using AWS SDKs.
55. 55© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Versioning
Protects from accidental overwrites and deletes with
no performance penalty.
Generates a new version with every upload.
Allows easily retrieval of deleted objects or roll back
to previous versions.
Three states of an Amazon S3 bucket
Un-versioned (default)
Versioning-enabled
Versioning-suspended
Versioning Enabled
Key: photo.gif
ID: 121212
Key: photo.gif
ID: 111111
56. 56© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Storage Classes
Storage Class Durability Availability Other Considerations
Amazon S3
Standard
99.999999999% 99.99% None
Amazon S3
Standard -
Infrequent
Access (IA)
99.999999999% 99.99% • Retrieval fee associated
with objects
• Most suitable for
infrequently accessed
data
Glacier 99.999999999% 99.99% (after you
restore objects)
• Not available for real-time
access
• Must restore objects
before you can access
them
57. 57© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Object Lifecycle
Lifecycle management defines how Amazon S3 manages
objects during their lifetime. Some objects that you store in an
Amazon S3 bucket might have a well-defined lifecycle:
Log files
Archive documents
Digital media archives
Financial and healthcare records
Raw genomics sequence data
Long-term database backups
Data that must be retained for regulatory compliance
58. 58© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Glacier
Long term low-cost archiving service
Optimal for infrequently accessed data
Designed for 99.999999999% durability
3-5 hours retrieval time
Less than $0.01 per GB / month (depending on region)
59. 59© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
SoundCloud Case Study
SoundCloud:
Operates worldwide.
Enables users to upload 12 hours of audio material to its platform every minute.
Each audio file must be transcoded and stored in multiple formats.
Logs and analyzes billions of events.
The AWS Solution:
SoundCloud uses a storage solution comprised of:
Amazon S3
Amazon Glacier
The audio files are:
Placed in Amazon S3.
Distributed from Amazon S3 via the SoundCloud website.
Copied to Amazon Glacier.
The company currently stores 2.5 PB of data on Amazon Glacier.
Amazon
Glacier
Amazon
S3
60. 60© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Instructor Demo
Amazon S3
61. 61© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Elastic Block Store (EBS)
Persistent block level storage volumes
offering consistent and low-latency performance
Automatically replicated within its Availability
Zone
Snapshots stored durably in Amazon S3
Amazon
EBS
62. 62© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EBS Lifecycle
Vast amounts of
unused space Create
Call CreateVolume
1 GB to 16 TB
Attach
Call AttachVolume to affiliate with
one Amazon EC2 instance
Attached
and
In Use
• Format from Amazon EC2
instance OS
• Mount formatted drive
CreateSnapshot
Snapshot to
Amazon S3
Detach
Call DetachVolume
Deleted
Call DeleteVolume
63. 63© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EBS Facts
You can create:
EBS Magnetic volumes from 1 GiB to 1 TiB in size.
EBS General Purpose (SSD) and Provisioned IOPS (SSD)
volumes up to 16 TiB in size.
You can use encrypted EBS volumes to meet a wide
range of data at-rest encryption requirements for
regulated/audited data and applications.
You can create point-in-time snapshots of EBS volumes,
which are persisted to Amazon S3.
64. 64© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EBS Use Cases
OS – Use for boot/root volume, secondary volumes
Databases – Scales with your performance needs
Enterprise applications – Provides reliable block storage to run
mission-critical applications
Business continuity – Minimize data loss and recovery time by
regularly backing up using EBS Snapshots
Applications – Install and persist any application
65. 65© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EBS Pricing
* Check Amazon EBS Pricing page for current pricing for all regions.
Pay for what you provision:
Pricing based on region
AWS GovCloud (US) Pricing page
Review Pricing Calculator online
Pricing is available as:
Storage
IOPS
66. 66© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EBS Scope
Amazon EBS Volumes are in a Single Availability Zone
Availability Zone A
EBS Volume 1
Availability Zone B
EBS Volume 2
Volume data is replicated across multiple servers in an Availability Zone.
67. 67© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EBS and Amazon S3
Amazon EBS Amazon S3
Paradigm Block storage with file system Object store
Performance Very fast Fast
Redundancy Across multiple servers in an
Availability Zone
Across multiple facilities in a Region
Security EBS Encryption – Data volumes
and Snapshots
Encryption
Access from the
Internet?
No (1) Yes (2)
Typical use case It is a disk drive Online storage
(1) Accessible from the Internet if mounted to server and set up as FTP, etc.
(2) Only with proper credentials, unless ACLs are world-readable
68. 68© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Instance Storage
Local, complimentary direct attached block storage resource.
Availability, number of disks, and size is based on EC2
instance type.
Storage optimized instances for up to 365,000 Read IOPS
and 315,000 First Write IOPS.
SSD or magnetic.
No persistence.
All data is automatically deleted when an EC2 instance stops,
fails or is terminated.
69. 69© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Reboot vs. Stop vs. Terminate
Characteristic Reboot Stop/Start
(EBS-backed instances only)
Terminate
Host computer The instance stays on the
same host computer.
The instance runs on a new
host computer.
N/A
Private and public
IP addresses
Stay the same. Instance keeps its private IP
address and gets a new public
IP address.
N/A
Elastic IP addresses
(EIP)
EIP remains associated with
the instance.
EIP remains associated with the
instance.
The EIP is disassociated from the
instance.
Instance store
volumes
The data is preserved. The data is erased. The data is erased.
EBS volume The volume is preserved. The volume is preserved. The volume is deleted by default.
Billing Instance billing hour doesn’t
change.
You stop incurring charges as
soon as state is changed to
stopping.
You stop incurring charges as
soon as state is changed to
shutting-down.
70. 70© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Networking
Amazon VPC
71. 71© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Virtual Private Cloud (VPC)
Provision a private, isolated virtual network
on the AWS cloud.
Have complete control over your virtual
networking environment.
Amazon
VPC
72. 72© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
VPCs and Subnets
A subnet defines a range of IP addresses in your
VPC.
You can launch AWS resources into a subnet that you
select.
A private subnet should be used for resources that
won’t be accessible over the Internet.
A public subnet should be used for resources that will
be accessed over the Internet.
Each subnet must reside entirely within one Availability
Zone and cannot span zones.
73. 73© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon VPC Example
Availability Zone A
Virtual Private Cloud
AWS Cloud
Public Subnet
Internet
Virtual Private Cloud
Availability Zone B
Private Subnet
Availability Zone C
VPN Only Subnet
DB Server DB Server
App Server
DB Server DB Server
DB Server
Web Server Web Server
NAT
Customer
Network
R
74. 74© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Security in Your VPC
Security groups
Network access
control lists
(ACLs) Subnet
10.0.0.0/24
Subnet
10.0.1.0/24
Internet GatewayVPN Gateway
VPC Router
10.0.0.0/16
Security Group Security
Group
Security
Group
Network ACL Network ACL
Routing Table Routing Table
instance instance instance instance
75. 75© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
VPN Connections
VPN Connectivity option Description
AWS Hardware VPN You can create an IPsec, hardware VPN connection
between your VPC and your remote network.
AWS Direct Connect AWS Direct Connect provides a dedicated private
connection from a remote network to your VPC.
AWS VPN CloudHub You can create multiple AWS hardware VPN
connections via your VPC to enable communications
between various remote networks.
Software VPN You can create a VPN connection to your remote
network by using an Amazon EC2 instance in your VPC
that’s running a software VPN appliance.
76. 76© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Knowledge Check Answers
Q: What AWS service would help support your web application to offload
serving static assets and store user uploaded images and video off-
instance?
Q: How would you find out the private and public IP addresses for an EC2
instance?
Q: What acts as an additional layer of security at the subnet level in a
VPC?
True or False: S3 Provides unlimited storage.
True
Retrieve the instance metadata. http://169.254.169.254/latest/meta-data/
Amazon S3
Network ACLs
77. 77© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Module 3
Security, Identity, and Access
Management
78. 78© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Shared Responsibility – AWS
AWS
Client-side Data Encryption
and Data Integrity
Authentication
Server-side Encryption
(File System and/or Data)
Network Traffic Protection
(Encryption/Integrity/Identity)
Platform, Applications, Identity and Access Management
Operating System, Network and Firewall Configuration
Customer Data
Customer
Foundation Services
Compute Storage Database Network
AWS Global
Infrastructure Regions
Availability Zones Edge
Locations
79. 79© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Physical Security
24/7 trained security staff
AWS data centers in nondescript and undisclosed facilities
Two-factor authentication for authorized staff
Authorization for data center access
80. 80© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Hardware, Software, and Network
Automated change-control process
Bastion servers that record all access attempts
Firewall and other boundary devices
AWS monitoring tools
81. 81© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Certifications and Accreditations
ISO 9001, ISO 27001, ISO 27017, ISO 27018, IRAP (Australia), MLPS Level 3 (China),
MTCS Tier 3 Certification (Singapore) and more …
82. 82© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
SSL Endpoints
VPC
Secure Transmission
Establish secure
communication
sessions (HTTPS)
using SSL/TLS.
Instance Firewalls
Configure firewall
rules for instances
using Security
Groups.
SSL Endpoints Security Groups
Network Control
In your Virtual
Private Cloud, create
low-level networking
constraints for
resource access.
Public and private
subnets, NAT and
VPN support.
SSL Endpoints
83. 83© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Security Groups
SSL Endpoints Security Groups
Instance Firewalls
Configure firewall
rules for instances
using Security
Groups.
VPC
Secure Transmission
Establish secure
communication
sessions (HTTPS)
using SSL/TLS.
Network Control
In your Virtual
Private Cloud, create
low-level networking
constraints for
resource access.
Public and private
subnets, NAT and
VPN support.
84. 84© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Multi-Tier Security Groups
HTTP
SSH/RDP
Ports 80 and 443 only
open to the Internet
Engineering staff have SSH/RDP
access to Bastion Host
All other internet ports blocked by default
Bastion
85. 85© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Virtual Private Cloud (VPC)
VPCSSL Endpoints Security Groups
Network Control
In your Virtual
Private Cloud, create
low-level networking
constraints for
resource access.
Public and private
subnets, NAT and
VPN support.
Instance Firewalls
Configure firewall
rules for instances
using Security
Groups.
Secure Transmission
Establish secure
communication
sessions (HTTPS)
using SSL/TLS.
86. 86© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Identity and Access Management (IAM)
AWS IAM
3
Manage federated users
and their permissions
2
Manage AWS IAM roles
and their permissions
1
Manage AWS IAM users
and their access
87. 87© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Authentication
Authentication
AWS Management Console
User Name and Password
IAM User
88. 88© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Authentication
Access Key ID: AKIAIOSFODNN7EXAMPLE
Secret Access Key: wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
Java Python .NET
AWS SDK & APIAWS CLI
Authentication
AWS CLI or SDK API
Access Key and Secret Key
IAM User
89. 89© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM User Management - Groups
User D
DevOps Group
User C
AWS Account
TestDev Group
User BUser A
90. 90© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Authorization
Authorization
Policies:
Are JSON documents to
describe permissions.
Are assigned to Users,
Groups or Roles.
IAM User IAM Group
IAM Roles
91. 91© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Policy Elements
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "Stmt1453690971587",
"Action": [
"ec2:Describe*",
"ec2:StartInstances",
"ec2:StopInstances”
],
"Effect": "Allow",
"Resource": "*",
"Condition": {
"IpAddress": {
"aws:SourceIp": "54.64.34.65/32”
}
}
},
{
"Sid": "Stmt1453690998327",
"Action": [
"s3:GetObject*”
],
"Effect": "Allow",
"Resource": "arn:aws:s3:::example_bucket*”
}
]
}
IAM Policy
92. 92© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Policy Assignment
IAM User
IAM Group
Assigned Assigned
IAM Policy
93. 93© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Policy Assignment
IAM User
IAM Group
IAM Roles
Assigned Assigned
Assigned
IAM Policy
94. 94© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Roles
An IAM role uses a policy.
An IAM role has no associated credentials.
IAM users, applications, and services may assume IAM
roles.
IAM Roles
95. 95© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Policy Assignment
IAM User
IAM Group
IAM Roles
Assigned Assigned
Assigned
IAM Policy
IAM User
Assumed Assumed
AWS Resources
96. 96© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Application Access to AWS Resources
Python application hosted on an Amazon EC2 Instance
needs to interact with Amazon S3.
AWS credentials are required:
Option 1: Store AWS Credentials on the Amazon EC2 instance.
Option 2: Securely distribute AWS credentials to AWS Services
and Applications.
IAM Roles
97. 97© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Roles - Instance Profiles
Amazon EC2
App &
EC2 MetaData Service
http://169.254.169.254/latest/meta-data/iam/security-credentials/rolename
Amazon S3
1
2
3
4
Create Instance
SelectIAMRole
ApplicationinteractswithS3
98. 98© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Roles – Assume Role
IAM Restricted Policy
IAM User A-1
AWS Account A
IAM Admin RoleIAM Admin Policy
Assigned
Assume
Assigned
1
2
IAM User B-1
AWS Account B
Amazon S3
Assume
4
Access
53
Access
1
99. 99© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Temporary Security Credentials (AWS STS)
Session
Access Key Id
Secret Access Key
Session Token
Expiration
Temporary Security Credentials
15 minutes to 36 hours
Use Cases
Cross account access
Federation
Mobile Users
Key rotation for Amazon EC2-
based apps
100. 100© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Application Authentication
AWS IAM Application
No Support No Support
OS
101. 101© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Authentication and Authorization
Authentication
AWS Management Console
• User Name and Password
AWS CLI or SDK API
• Access Key and Secret Key
Authorization
Policies
IAM User IAM Group
IAM Roles
102. 102© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Best Practices
Delete AWS account (root) access keys.
Create individual IAM users.
Use groups to assign permissions to IAM users.
Grant least privilege.
Configure a strong password policy.
Enable MFA for privileged users.
103. 103© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Best Practices (cont.)
Use roles for applications that run on Amazon EC2
instances.
Delegate by using roles instead of by sharing credentials.
Rotate credentials regularly.
Remove unnecessary users and credentials.
Use policy conditions for extra security.
Monitor activity in your AWS account.
104. 104© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Resource-Based Policies
Are an alternative to IAM and supported by some
services.
Grant cross-account access to your resources.
Use a principal to uniquely identify account in the policy.
Supported AWS services include :
Amazon S3 Bucket Policy
Amazon SNS Topic Policy
Amazon SQS Queue Policy
Amazon Glacier Vault Policy
AWS OpsWorks Stack Policy
AWS Lambda Function Policy
105. 105© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Knowledge Check Answer
Q: Your web application needs to read/write an Amazon DynamoDB table
and an Amazon S3 bucket. This operation requires AWS credentials and
authorization to use AWS services. What service would you use?
AWS IAM Role
106. 106© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Instructor Demo
IAM
107. 107© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Module 4
Databases
108. 108© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
SQL and NoSQL Databases
SQL NoSQL
Data Storage Rows and Columns Key-Value
Schemas Fixed Dynamic
Querying Using SQL Focused on collection of
documents
Scalability Vertical Horizontal
ISBN Title Author Format
9182932465265 Cloud Computing
Concepts
Wilson,
Joe
Paperback
3142536475869 The Database
Guru
Gomez,
Maria
eBook
SQL NoSQL
{
ISBN: 9182932465265,
Title: “Cloud Computing Concepts”,
Author: “Wilson, Joe”,
Format: “Paperback”
}
109. 109© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Data Storage Considerations
No one size fits all.
Analyze your data requirements by considering:
Data formats
Data size
Query frequency
Data access speed
Data retention period
110. 110© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Managed Database Services
Compute Storage
AWS Global Infrastructure
Database
App Services
Deployment and Administration
Networking
Amazon DynamoDB
Amazon ElastiCache
Amazon RDS
Amazon Redshift
AWS Database Migration Service
111. 111© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Relational Database Service (RDS)
Cost-efficient and resizable capacity
Manages time-consuming database
administration tasks
Access to the full capabilities of Amazon
Aurora, MySQL, MariaDB, Microsoft SQL
Server, Oracle, and PostgreSQL databases
Amazon
RDS
112. 112© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon RDS Use Case
We were able to go from
concept to delivered product
in about six months with just
a handful of engineers.
Greg Scallan
Chief Architect, Flipboard
”
“ Flipboard is an online magazine
with millions of users and billions of
“flips” per month.
Flipboard is one of the world’s first
social media magazines.
Flipboard uses Amazon RDS and
its Multi-AZ capabilities to store
mission critical user data.
113. 113© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon RDS
Simple and fast to deploy
Manages common database administrative tasks
Compatible with your applications
Fast, predictable performance
Simple and fast to scale
Secure
Cost-effective
114. 114© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
DB Instances
DB Instances are the basic building blocks of
Amazon RDS.
They are an isolated database environment in the
cloud.
They can contain multiple user-created databases.
115. 115© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
How Amazon RDS Backups Work
Automatic Backups:
Restore your database to a
point in time.
Are enabled by default.
Let you choose a retention
period up to 35 days.
Manual Snapshots:
Let you build a new
database instance from a
snapshot.
Are initiated by the user.
Persist until the user deletes
them.
Are stored in Amazon S3.
116. 116© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Cross-Region Snapshots
Are a copy of a database
snapshot stored in a
different AWS Region.
Provide a backup for
disaster recovery.
Can be used as a base
for migration to a
different region.
117. 117© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon RDS Security
Run your DB instance in an Amazon VPC.
Use IAM policies to grant access to Amazon RDS resources.
Use security groups.
Use Secure Socket Layer (SSL) connections with DB instances
(Amazon Aurora, Oracle, MySQL, MariaDB, PostgreSQL, Microsoft
SQL Server).
Use Amazon RDS encryption to secure your RDS instances and
snapshots at rest.
Use network encryption and transparent data encryption (TDE) with
Oracle DB and Microsoft SQL Server instances.
Use the security features of your DB engine to control access to
your DB instance.
118. 118© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
A Simple Application Architecture
Amazon RDS database
instance
Amazon EC2
Application Servers
Elastic Load Balancing
load balancer instance
DB snapshots in
Amazon S3
119. 119© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Multi-AZ RDS Deployment
With Multi-AZ operation, your database is
synchronously replicated to another AZ in the same
AWS Region.
Failover automatically occurs to the standby in case
of master database failure.
Planned maintenance is applied first to standby
databases.
120. 120© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
A Resilient, Durable Application Architecture
Amazon RDS database
instances:
Master and Multi-AZ standby
Application, in Amazon
EC2 instances
Elastic Load Balancing
load balancer instance
DB snapshots in
Amazon S3
121. 121© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon RDS Best Practices
Monitor your memory, CPU, and storage usage.
Use Multi-AZ deployments to automatically provision and maintain a
synchronous standby in a different Availability Zone.
Enable automatic backups.
Set the backup window to occur during the daily low in WriteIOPS.
To increase the I/O capacity of a DB instance:
Migrate to a DB instance class with high I/O capacity.
Convert from standard storage to provisioned IOPS storage and use a DB
instance class optimized for provisioned IOPS.
Provision additional throughput capacity (if using provisioned IOPS storage).
If your client application is caching the DNS data of your DB instances,
set a TTL of less than 30 seconds.
Test failover for your DB instance.
122. 122© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon DynamoDB
Store any amount of data with no limits
Fast, predictable performance using SSDs
Easily provision and change the request
capacity needed for each table
Fully managed, NoSQL database serviceAmazon
DynamoDB
123. 123© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
DynamoDB Use Case
AdRoll, an online advertising platform, serves 50
billion impressions a day worldwide with its
global retargeting platforms.
We spend more on snacks
than we do on Amazon
DynamoDB.
Valentino Volonghi
CTO, Adroll
”
“
Adroll Uses AWS to grow by more than
15,000% in a year
Needed high-performance, flexible
platform to swiftly sync data for
worldwide audience
Processes 50 TB of data a day
Serves 50 billion impressions a day
Stores 1.5 PB of data
Worldwide deployment minimizes
latency
124. 124© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
DynamoDB Data Model
Table:
Music
Items
Attributes (name-value pairs)
Artist Song
Title
Album
Title
Year Genre
125. 125© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Primary Keys
Partition Key
Sort Key
Table: Music
Partition Key: Artist
Sort Key: Song Title
(DynamoDB maintains a sorted index for both keys)
Table:
Music
Artist Song
Title
Album
Title
Year Genre
126. 126© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Local Secondary Index
Partition Key
Sort Key
LSI
Table: Music
Partition Key: Artist
Sort Key: Song Title
LSI: Album Title
Table:
Music
Artist Song
Title
Album
Title
Year Genre
127. 127© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Global Secondary Index
Choose which attributes
to project (if any)
Table: Music
Partition Key: Artist
Sort Key: Song Title
GSI: MusicGSI
Partition Key: Genre
Sort Key: Year
Table:
Music
Artist
Song
Title
Album
Title
Year Genre
Genre Year Song Title
128. 128© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Provisioned Throughput
You specify how much provisioned throughput capacity
you need for reads and writes.
Amazon DynamoDB allocates the necessary machine
resources to meet your needs.
Read capacity unit:
One strongly consistent read per second for items as large
as 4 KB.
Two eventually consistent reads per second for items as
large as 4 KB.
Write capacity unit:
One write per second for items as large as 1 KB.
129. 129© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Supported Operations
Query:
Query a table using the partition key and an optional sort key filter.
If the table has a secondary index, query using its key.
It is the most efficient way to retrieve items from a table or
secondary index.
Scan:
You can scan a table or secondary index.
Scan reads every item – slower than querying.
You can use conditional expressions in both Query and Scan
operations.
130. 130© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Simple Application Architecture
Elastic Load
Balancing Amazon EC2
app instances
Clients
Amazon
DynamoDB
Business logic
131. 131© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon RDS and Amazon DynamoDB
Factors Relational (Amazon RDS) NoSQL (Amazon DynamoDB)
Application
Type
• Existing database apps
• Business process–centric apps
• New web-scale applications
• Large number of small writes and
reads
Application
Characteristics
• Relational data models,
transactions
• Complex queries, joins, and
updates
• Simple data models, transactions
• Range queries, simple updates
Scaling
Application or DBA–architected
(clustering, partitions, sharding)
Seamless, on-demand scaling based
on application requirements
QoS
• Performance–depends on data
model, indexing, query, and
storage optimization
• Reliability and availability
• Durability
• Performance–Automatically
optimized by the system
• Reliability and availability
• Durability
132. 132© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Database Considerations
If You Need Consider Using
A relational database
service with minimal
administration
Amazon RDS
• Choice of Amazon Aurora, MySQL, MariaDB, Microsoft
SQL Server, Oracle, or PostgreSQL database engines
• Scale compute and storage
• Multi-AZ availability
A fast, highly scalable
NoSQL database
service
Amazon DynamoDB
• Extremely fast performance
• Seamless scalability and reliability
• Low cost
A database you can
manage on your own
Your choice of AMIs on Amazon EC2
and Amazon EBS that provide scale compute and
storage, complete control over instances, and more.
133. 133© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Module 5
AWS Elasticity and
Management Tools
134. 134© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Auto Scaling
Scale your Amazon EC2 capacity
automatically
Well-suited for applications that experience
variability in usage
Available at no additional chargeAuto
Scaling
135. 135© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Trio of Services
Latency
Utilization
CloudWatchAuto Scaling
Elastic Load
Balancing
Auto Scaling group
Execute AS
Policy
136. 136© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Auto Scaling Benefits
Better Cost
Management
Better
Availability
Better Fault
Tolerance
137. 137© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Launch Configurations
A launch configuration is a template that an Auto
Scaling group uses to launch EC2 instances.
When you create a launch configuration, you can
specify:
AMI ID
Instance type
Key pair
Security groups
Block device mapping
User data
138. 138© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Auto Scaling Groups
Contain a collection of EC2 instances that share
similar characteristics.
Instances in an Auto Scaling group are treated as a
logical grouping for the purpose of instance scaling
and management. Auto Scaling group
Minimum size
Desired capacity
Maximum size
Scale out as needed
139. 139© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Dynamic Scaling
You can create a scaling policy that uses
CloudWatch alarms to determine:
When your Auto Scaling group should scale out.
When your Auto Scaling group should scale in.
You can use alarms to monitor:
Any of the metrics that AWS services send to Amazon
CloudWatch.
Your own custom metrics.
140. 140© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Auto Scaling Basic Lifecycle
instances
Auto Scaling group
Scale Out
Amazon CloudWatch
Scheduled Event
Scale In
Amazon CloudWatch
Scheduled Event
Launch
Instance
Terminate
Instance X
Attach to Group
Detach from
Group
141. 141© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Elastic Load Balancing
Distributes traffic across multiple instances
Supports health checks to detect unhealthy
Amazon EC2 instances
Supports the routing and load balancing of
HTTP, HTTPS, and TCP traffic to Amazon EC2
instances
Elastic Load
Balancing
142. 142© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Elastic Load Balancing Example
143. 143© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
How It Works
Availability Zone A Availability Zone B
load balancer
X
144. 144© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Load Balancer Types
Availability Zone A Availability Zone B
EC2 instancesEC2 instances
Internet-Facing
load balancer
EC2 instancesEC2 instances
HTTPS
SSL Handler/Load
Balancer
HTTPS Traffic
Availability Zone BAvailability Zone AAvailability Zone B
EC2 instancesEC2 instances
Internal
load balancer
private subnetprivate subnet
public subnet public subnet
EC2 instance EC2 instance
Availability Zone A
145. 145© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Back-end Instances for Your Load Balancer
Health Checks
Security Groups
Subnets
Register
De-Register Instances
146. 146© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon CloudWatch
A monitoring service for AWS cloud resources and
the applications you run on AWS
Visibility into resource utilization, operational
performance, and overall demand patterns
Custom application-specific metrics of your own
Accessible via AWS Management Console, APIs,
SDK, or CLI
Amazon
CloudWatch
147. 147© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon CloudWatch Facts
Monitor other AWS resources
View graphics and statistics
Set Alarms
148. 148© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon CloudWatch Architecture
AWS resources
that support
CloudWatch
Amazon
CloudWatch
Amazon
CloudWatch
Alarm
SNS Email
Notification
Auto Scaling
Available
Statistics
Statistics
Consumer
AWS Management
Console
CloudWatch Metrics
CPUUtilization
StatusCheckFailed
Custom
Application-
Specific Metrics
PageViewCount
149. 149© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
CloudWatch Metrics Examples
150. 150© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
CloudWatch Alarms
151. 151© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Supported AWS Services
Auto Scaling
Amazon
CloudFront
Amazon CloudWatch
Amazon
CloudSearch
Amazon
DynamoDB
Amazon EC2
Amazon
ElastiCache
Amazon EBS
Elastic Load
Balancing
Amazon EMR
Amazon Kinesis Amazon EC2
Container Service
AWS OpsWorks
Amazon Redshift
Amazon RDS
Amazon
Route 53
Amazon SNS
Amazon
SQS
Amazon
SWF
Amazon S3AWS Storage
Gateway
Amazon
WorkSpaces
Amazon Machine
Learning
AWS Lambda AWS WAF
152. 152© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Trusted Advisor
Best practice and recommendation engine.
Provides AWS customers with performance and
security recommendations in four categories: cost
optimization, security, fault tolerance, and
performance improvement.
AWS Trusted
Advisor
153. 153© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Cost Optimization
Amazon EC2 Reserved Instance Optimization
Low Utilization Amazon EC2 Instances
Idle Load Balancers
Underutilized Amazon EBS Volumes
Unassociated Elastic IP Addresses
Amazon RDS Idle DB Instances
154. 154© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Security
Security Groups
AWS IAM Use
Amazon S3 Bucket Permissions
MFA on Root Account
AWS IAM Password Policy
Amazon RDS Security Group Access Risk
155. 155© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Fault Tolerance
Amazon EBS Snapshots
Load Balancer Optimization
Auto Scaling Group Resources
Amazon RDS Multi-AZ
Amazon Route 53 Name Server Delegations
ELB Connection Draining
156. 156© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Performance Improvement
High Utilization Amazon EC2 Instances
Service Limits
Large Number of Rules in EC2 Security Group
Over Utilized Amazon EBS Magnetic Volumes
Amazon EC2 to EBS Throughput Optimization
Amazon CloudFront Alternate Domain Names
157. 157© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Appendix
158. 158© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Cloud Computing Concepts
159. 159© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
What is cloud computing?
Cloud computing is on-demand delivery of IT resources and
applications via the Internet with pay-as-you-go pricing.
160. 160© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Essential Characteristics of Cloud Computing
On-Demand Self
Services
Broad Network Access
Resource Pooling
Rapid Elasticity
Measured Service
161. 161© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
On-Demand Self Services & Broad Network Access
User provisions computing resources as needed.
User interacts with cloud service provider through an online
control panel.
Clear solutions are available through a variety of network-
connected devices and over varying platforms.
Internetclient mobile client
162. 162© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Resource Pooling
Securely separate resources to service multiple customers.
163. 163© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Rapid Elasticity
Resources are quickly scalable and flexible based on
business needs.
164. 164© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Measured Service
Pay for services as you go.
Electrical services
analogy
165. 165© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
What Does My AWS Cloud Look Like?
166. 166© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Data Center Design Models
167. 167© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Application Design Model
One-Tier Model
Clients
Mainframe
Two-Tier Model
SQL
Client Database
Servers
Three-Tier Model
Client Application
Server
Database
Servers
SQL, ODBC,
JDBC
HTTP,
RPC
N-Tier Model
Client Application
Servers
Web
Server Middleware
Database
Servers
168. 168© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Web Services Model
Web Server Application Server Database Server
Serves web pages • Implements business logic
• Manipulates data
• Data mining
• Accesses data store
• High transaction rate
• High bandwidth
• Low latency
169. 169© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Marketplace
Enable success in the cloud with software access across
your technology stack.
Security
Network Storage
Dev Ops
Media
Open Source & OS
Software Categories
Business Intelligence
Database
And Many More
170. 170© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Marketplace
Leverage a broad catalog of IT software to support your
workload needs.
171. 171© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Storage Concepts and
Solutions
172. 172© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Block and File Level Storage
Block Level Storage File Level Storage
Block File
173. 173© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Storage Technologies
DAS NAS SAN
Client
Server Server
Client
NAS Storage
Client
Server
Client
DAS StorageDAS Storage Server
Server Server
FC Switch
Client Client
SAN Storage
RAID 1
RAID 2
174. 174© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Region Considerations
Amazon S3 creates a bucket in the region you
select.
You can choose a region to:
Optimize latency
Minimize costs
Address regulatory requirements
Objects stored in a region never leave the region
unless you explicitly transfer them to another
region.
175. 175© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 Objects
Objects are the fundamental entities stored in Amazon S3.
When using the console, you can think of them as files.
Objects consist of data and metadata. The data portion is opaque to
Amazon S3. The metadata is a set of name-value pairs that describe
the object.
Default metadata such as the date last modified
Standard HTTP metadata such as Content-Type
Custom metadata at the time the object is stored
A key that uniquely identifies as object within its bucket
176. 176© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 + Amazon Glacier
S3 Lifecycle policies allow you to delete or move
objects based on age and set rules per S3 bucket.
bucket with
objects
30 Days
Glacier
archive
365 Days
177. 177© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
EBS Performance
EBS Magnetic
40-200 IOPS
EBS General Purpose SSD
SSD backed
3 IOPS / GB
Burstable to 3,000 IOPS and up to 10,000 IOPS
EBS Provisioned IOPS SSD
SSD backed
Up to 20,000 IOPS consistently
Up to 320 MB/s throughput
178. 178© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon CloudFront
Easy and cost effective way to distribute
content to end users
Low latency, high data transfer speeds
Deliver your entire website, including static,
dynamic, and streaming content using a global
network of edge locations
Amazon
CloudFront
179. 179© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
How You Configure CloudFront to Deliver Your
Content
Developer
S3 Bucket or
HTTP Server
1
Objects/Data
2
Web Distribution
CloudFront
3
http://d111111abcdef8.cloudfront.net
Edge
Locations
Your Distribution’s
Configuration
4
180. 180© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
How CloudFront Delivers Content to Your Users
Amazon S3 Server
or HTTP Server
User Website
example.com
1 2
3a
Edge location
Object/Data
3bObject/Data
3/3c
181. 181© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Networking Concepts
182. 182© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
What is a Network?
A network is two or more computers linked
to share resources, exchange files, or allow
electronic communications.
Network Types:
Local Area Network (LAN)
Wide Area Network (WAN)
Virtual Private Network (VPN)
WAN
LAN LAN
VPN
183. 183© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Physical vs. Logical Topology
A physical topology defines how the systems are physically
connected.
A logical topology defines how the systems communicate
across the physical topologies.
184. 184© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Physical Network Hardware/Devices
Workstations/
Devices
Router
Telecommunications
Firewall
Servers
Internet
Router
Firewall
Workstations/Devices
Switch
Switch
Servers
185. 185© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Networking in Your VPC
You can use the following components to configure networking in
your VPC:
IP Addresses
Elastic Network Interfaces
Route Tables
Internet Gateways
Network Address Translation (NAT)
Dynamic Host Configuration Protocol (DHCP) Options Sets
Domain Name System (DNS)
VPC Peering
VPC Endpoints
VPC Flow Logs
186. 186© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Data Center Security
187. 187© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Physical & Environmental Security
Lock your data center.
Only provide access to those who need it.
Keep track of access.
Mount servers on racks with locks.
Have redundant utilities.
Build your data center with security in mind.
188. 188© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Network Security
Identification & Authentication
Firewalls
Patching
Virus Protection
Encryption
189. 189© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Access to AWS Resources
Temporary Security Credentials
Security Token Service
AssumeRole
AssumeRoleWithSAML
AssumeRoleWithWebIdentity
190. 190© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
sts:AssumeRole
IAM Role
Permissions
Actual
Permissions
[optional]
Permissions
passed with
AssumeRole
191. 191© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Access to AWS Resources
Temporary Security Credentials
Security Token Service
AssumeRole
AssumeRoleWithSAML
AssumeRoleWithWebIdentity
Federation
GetFederationToken
192. 192© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
sts:GetFederationToken
IAM User’s
Permissions
Actual
Permissions
Permissions passed with
GetFederationToken
193. 193© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Services support for IAM Roles
AWS CLI on Amazon EC2
AWS CloudTrail logs to Amazon S3
Amazon Elastic Transcoder access to Amazon S3
AWS Elastic Beanstalk access to AWS services
AWS Lambda code access to AWS services
Many more …
194. 194© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Federation
IAM federation may be used for federated
access to:
AWS Management Console
AWS APIs
Supported Identities:
AWS Directory Service
Microsoft Active Directory
OpenID Connect (OIDC) such as Amazon
Cognito and Login with Amazon
SAML 2.0
AWS Directory Service Amazon Cognito
195. 195© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IAM Federation using SAML 2.0
AWS Account
AWS Region
Kinesis
AWS STS
Corporate Data Center
User
Client
Application
Identity Store
(LDAP)
Identity Provider
(Portal)
1
2
3
4
5
6
7
User Login
Client app request
to IDP
Portal sends client
SAML assertion
App calls AssumeRoleWithSAML
AWS returns temporary security
credentials
App uses credentials to access
AWS resource
196. 196© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon Cognito Federation for Mobile Applications
AWS Account
AWS Region
Cognito
DynamoDB
AWS STS
User
Identity
Provider
(Login with
Amazon)
Mobile Client
1
2
3
4
5
App accessed
Redirect for
authentication and
receive an ID
token
Exchange ID token for
Cognito token
Exchange Cognito token
for temporary AWS
credentials
Uses the temporary credentials to
access AWS services
197. 197© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS CloudTrail
Records AWS API calls for accounts.
Delivers log files with information to an Amazon S3
bucket.
Makes calls using the AWS Management Console, AWS
SDKs, AWS CLI and higher-level AWS services.
AWS CloudTrail Amazon S3 Bucket
Logs
198. 198© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Security Groups
Allow access to IP address ranges or Amazon EC2
instances you specify.
Use VPC security groups to control access to a DB
instance inside a VPC.
199. 199© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
DB Parameter & Option Groups
DB Parameter Groups:
Contain engine configuration values that can be applied to one or
more DB instances of the same instance type.
Amazon RDS applies a default DB parameter group when you create
DB instance, which contains defaults for the specific database engine
and instance class of the DB instance.
DB Option Groups:
Tools that simplify database
management.
Currently available for Oracle,
Microsoft SQL Server, and MySQL 5.6
DB instances.
200. 200© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Supported Operations
Table Operations:
Create, update, and delete tables.
After creation, you can increase or decrease provisioned
throughput.
Retrieve the table’s status, the primary key, and when the table was
created.
You can list all tables in your account for a region.
Item Operations:
Add, update, and delete items from a table.
Add, update, and delete existing attributes from an item.
Perform conditional updates.
Retrieve a single item or multiple items.
201. 201© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Auto Scaling
Minimum
Health Check
monitors running
instances within an
Auto Scaling
Group.
If an unhealthy
instance is found, it
can be replaced.
Manual Scaling
Specify a new
minimum for your
Auto Scaling
Group.
Manually invoke
Auto Scaling
Policies.
Scheduled
Scaling
Scaling functions
are performed as a
function of time
and date.
On Demand
Scaling
You create a policy
to scale your
resources.
Define when to
scale using
CloudWatch
Alarms.
Scaling Plans
202. 202© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Request Routing
client
DNS server
Load Balancer
Routing
Algorithm
Auto Scaling group
security group
EC2 instance
Auto Scaling group
security group
EC2 instance
EC2 instance
IP Addresses
elb.example.org
203. 203© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
Listeners
A listener is a process that checks for connection requests.
Front-end connections are:
Client to load balancer connections.
Configured with a protocol and a port.
Back-end connections are:
Load balancer to back-end instance connections.
Configured with a protocol and a port .
ELB supported protocols:
HTTP
HTTPS
TCP
SSL
204. 204© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.
This work may not be reproduced or redistributed, in whole or in part, without
prior written permission from Amazon Web Services, Inc. Commercial
copying, lending, or selling is prohibited.
Errors or corrections? Email us at aws-course-feedback@amazon.com.
For all other questions, contact us at:
https://aws.amazon.com/contact-us/aws-training/.
All trademarks are the property of their owners.