Please enable JavaScript.
Coggle requires JavaScript to display documents.
AWS, AWS Regions - Coggle Diagram
AWS
AWS CloudFront
-
Improves read performance, content is cached at the edge locations
-
DDoS protection, integration with Shield, AWS Web Application firewall
-
Origins
what can you use CloudFront for (caching data in edge location to allow clients to read/write them quicker)
-
-
-
-
-
-
-
-
-
-
Advanced concepts
Pricing
-
-
-
three price classes
-
Price class 200: most regions, but excludes the most expensive regions
NA, EU, Africa, South Asia
-
-
-
AWS global accelerator
instead of using public network (www) to connect to servers with specific IP (Unicast IP), that will get routed along the way and cause latency or request to be lost, use Global Accelerator with Anycast IP (one ip for all servers via Edge location) to leverage edge locations to forward traffic to AWS application ( more stable, less latency) same ip, so forwards traffic to closest destination :warning:
works with Elastic IP, EC2, ALB, NLB, public or private
-
GA vs CF
-
-
-
GA
-
-
Good for non-http, e.g. gaming (UDP), IoT (MQTT) or Voice over IP
-
-
ElasticBeanstalk
-
uses EC2, ASG, ELB RDS etc.
automatic handling of capacity provisioning, lb, scaling, app health monitoring, instance config
-
-
beanstalk is free, you pay for instances that it manages/creates (also ELB, ASG etc.)
Components
Components
Application, colelctio of ERlastic Beanstalk components (environments, versions, configurations)
-
Environment
Collection of AWS resources, running an app version (only one app version at a time)
-
you can create many evns, (dev test prod )
Development stage and want to reduce costs - use single instance mode (create one EC2 with Elastic IP)
Route 53
HA, scalable fully managed and Authoritative DNS
-
-
-
-
Records
each record contains
-
-
-
-
-
Alias free of charge
Alias vs CNAME :warning:
CNAME points hostname to any other hostname
ONLY FOR NON ROOT DOMAIN
e.g. for domain name something.domain.com you own
posible to do aka.something.domain.com
Alias Points hostname to AWS resource
work for root and non root domain aka.mydomain.com
free :warning:
-
-
-
Routing policies
Simple
-
-
if multiple values are returned, a random one is chosen by the client
-
when alias enabled, only one AWS reource can be specified
-
Weighted
-
-
-
-
-
-
if all records have weight 0, then all will be returned equally
Failover
mandatory healthcheck, auto failover
Latency based
-
-
-
germany users may be directed to US, if thats the lowest latency
-
Geolocation
-
specify location by continent, country or by US state, if thre's overlapping most precise loctation selected
-
-
-
-
-
-
-
-
S3
-
-
-
-
Security
user based
-
resource based
bucket policies
-
-
-
-
Blocking public access
blocking can be done by
-
-
-
block public and cross accoutn access to buckets and objects through any public bucket or access point policies
-
if yo uknow your bucket should never be public, leave these on
-
Networking
supports VPN endpoints, for instances in VPC without www internet
-
User Security
MFA Delete, can be required in versioned buckets to delete objects
pre signed urls, valid only for limited time (ex premium video service for logged in users)
-
Advanced S3 & Athena
MFA Delete
-
-
-
not need MFA for enabling versioning, listing deleted versions
-
Default encryption :warning: #
one way to force encryption is to use a bucket policy and refuse API call to PUT S3 object without encryption headers
-
Access logs
for audit purpose, you may want to log all access to S3 buckets
any request mate to S3, from any account, authorized or not, will be logged into another S3 bucket
-
:forbidden:do not set logging bucket to be the monitored bucket, it will create logging loop, and bucket will grow in size exponentially
-
-
-
Lifecycle rules
-
for infreq access, move them to STANDARD_IA
for archive objects, you don't need in real time, use GLACIER or DEEP_ARCHIVE
-
-
-
-
-
-
S3 Performance
automatic scales for high request rates, 100-200ms latency
app can achieve at least 3,500 PUT/COPY/POST/DELETE and 5,500 GET/HEAD requests per second per prefix ina bucket #
-
-
if you use SSE KMS, you may be impacted by KMS limits
-
-
Count towards the KMS quota per second (5500, 10000,30000 req based on region)
-
-
Multi-part upload to increase performance #
-
-
S3 Transfer acceleration
Increase transfer (up/down) speed by transferring file to an AWS edge location which will forward the data to the S3 bucket in the target region
-
-
-
S3 Event notifications
S3:ObjectCreated
S3:ObjectRemoved
S3:ObjectRestore,
S3:Replication
-
-
Use them to notify e.g. SNS, SQS, Lambda function
typically events are delivered in seconds, but can take a minute or longer
-
-
S3 requester Pays
bucket owners will pay for S3 storage and data transfer costs associated with their bucket in general
instead you might want the requester to pay for networking cost for downloading data from the bucket :warning:
-
-
Athena
-
-
supports CSV, JSON ORC, Avro and Parquet (built on Presto)
-
Use cases Business Inteligence, analytics, reporting, analyze & query VPC Flow Logs, ELB logs, CloudTrail trails, etc
-
-
-
EC2
Elastic Compute Cloud
-
-
-
-
EC2 SAA Level
-
Elastic IP (fixed public IP) otherwise assigned and available until instance is deleted, then you receive a new one when started again
Only 5 elastic ip in account available, can ask AWS to incerease
-
-
-
EC2 Hibernate
RAM state preserved, boot much faster OS not stopper/restarted
-
-
-
-
-
-
root volume must be EBS encrypted, not instance store and large
available for on demand, reserved
-
-
EC2 Nitro :fire:
next gen of ec2 isntances
new virtualiuzation tech
better performance
better networking
higher EBS (nitro for 64k IOPS max 32k non nitro
better security
-
Storage extras
AWS snow family
Highly Secure, portable devices to collect and process data at the edge and migrate data into and out of AWS
Data migration
SnowCone
-
small, portable computing,anywhere, rugged & secure, withstands harsh environments
-
device used for edge computing, storage, and data transfer
-
-
Can be sent back to AWS offline, or connect it to internet and use AWS DataSync to send data
-
-
-
Edge computing
-
-
process data while its being created in an edge location, truck on the road, ship on sea, mining station underground - places with limited or without internet access
-
2CPUs, 4GB RAM, wired or wireless access
-
-
-
-
-
Amazon FSx
-
-
FSx for Lustre
parallel distributed FS , for large scale computing
-
machine learning, High Performance Computing (HPC)
Video processing, Financial Modeling, Electronic Design Automation
Scales up to 100s of GB/s, millions of IOPS, sub-ms latencies
Storage options
SSD low latency, IOPS intensive workloads, small & random file operations
HDD throughput intensive workloads, large & sequential file operations
-
-
-
-
FSx File Gateway :warning: #
-
-
Windows native compatibility (SMB, NTFS, Active Directory)
-
Storage Gateway
Hybrid cloud for storage (part of infrastructure on premises, part on the cloud)
-
-
-
Use cases DR, backup & restore, tiered storage
-
Hardware appliance
-
Otherwise, you can use a Storage gateway Hardware appliance
-
-
-
-
-
-
AWS Security & Encryption: KMS, SSM, Parameter Store, Cloud HSM, Shield, WAF
-
-
-
KMS
Mult-region keys
-
-
-
-
-
-
use cases: global slient side enc, enc on global dynamo db, global aurora
-
-
-
-
-
-
-
-
-
KMS key types
SYMMETRIC AES-256 keys
-
-
when we create or use sym key, yo unever get access to unencrypted key - it is held in KMS and api has to be used to work with it
AWS managed key is free, CMK 1$/month
-
-
-
-
-
Key policies
controll access to KMs keys, similar to s3 bucket policied
-
-
Custom KMs key policy
define users, roles that can access the KMS key
-
-
RDS Autora ElastiCache
RDS
-
-
-
RDS backuips
-
-
-
-
-
7 days retention, can be increased to 35
-
-
-
RDS Multi AZ
-
one DNS, auto app failover to stanby replica
-
-
-
-
RDS Security :warning:`
RDS db usually deployed in private subnet, not public - make sure db not exposed to www
RDS security works via the help of SG, same as for EC2 - it controls which IP/SGs can communicate with RDS
-
-
Elasticache
-
-
-
-
-
aws take care of OS mainentance patching, etc.
-
HOW IT WORKS
App queries elasticache, if not available (cache miss) get from RDS and store in cache else "cache hit" and retrieve from Elasticache
-
Redis vs memcached
Redis Multi AZ with auto failover
read replicas scale reads and have high availability
data durability using AOF
backup dn restore features :warning:
memcached
multi-node for partitioning of data (sharding)
no high availability (replication)
non persistent
no backup and restore
multi-threaded architecture : :warning:
all caches in elasticache do not support IAM
IAM policies on Elasticache are only used for AWS API level security e.g. creating or removing cache
:warning:
Redis AUTH
you can set a "password/token" when you create a redis cluster
this is an extra level of security for your cache (on top of SG)
support SSL in flight encryption
-
Patterns for ElastiCache
Lazy loading: all the read data is cached, data can become stale in cache
-
-
Redis use case
-
-
each time a new element added, its ranked in real time, then addec in correct order
-
SQS SNS Kinesis, Active MQ
-
-
AWS Regions
AZ
Usually 3 per region, max is 6
each AZ is one or more discrete data centers with redundant power, networking and connectivity
e.g. region ap-southeast-2
AZ within will be ap-southeast-2a ,2b etc
each AZ is separated from each other, so one failing does not affect others
-
Choosing right region based on legal compliance
Proximity - e.g. low latency for users choose Region close to them
-
-
-