0% found this document useful (0 votes)
16 views

Aws 1

The document discusses cloud computing concepts including cloud deployment types, service models, and Amazon Web Services. It provides an overview of AWS services like EC2, security groups, pricing options, and instance types. EC2 is described as an IaaS offering that allows on-demand provisioning of virtual servers and other resources.

Uploaded by

Nishka Sharma
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views

Aws 1

The document discusses cloud computing concepts including cloud deployment types, service models, and Amazon Web Services. It provides an overview of AWS services like EC2, security groups, pricing options, and instance types. EC2 is described as an IaaS offering that allows on-demand provisioning of virtual servers and other resources.

Uploaded by

Nishka Sharma
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 72

Introduction

• 1. what is cloud computing?

• 2. Cloud deployment types?

• 3. Cloud service models?

• 4. Introduction to Amazon Web Services(AWS)

• 5. Task
1. What is cloud computing?

One demand delivery of compute power, database,


storage, application and other IT resources through a
cloud service platform via the internet with pay-as-you-go
pricing model.

“Cloud computing is a model for convenient, on-demand


network access to a shared pool of configuration
computing resources (e.g., network, servers, applications
and services) that can be rapidly provisioned and released
with minimal management effort or service provider
interaction”
Users | Resources
|
Cloud Engine – automation engine
(management free, self services on demand)
Aws Console
Management between resources and client

Why we need cloud?


Top Cloud platforms
• 1. AWS
• 2. Microsoft Azure
• 3. GCP
• 4. Alibaba
Oracle, Vmware, Fijitsu, IBM
• Characteristics of cloud:-
• 1. On demand self service
• 2. Broad network access
• 3. Scalability
• 4. Resource pooling
• 5. Measured services
Application
Cloud services model Data

Runtime
• IAAS
Middleware

• PAAS o/s

Virtualization
• SAAS
Server

Storage

Network
Platform Examples
PAAS(Platform-as-a-service)

AWS Elastic Beanstalk, Google App Engine,


and Adobe Commerce

SaaS(Software-as-a-service)

Gmail, Slack, and Microsoft Office 365

IaaS(Infrasturcture-as-a-service)

Amazon Web Services, Microsoft Azure, and


Google Compute Engine
Cloud deployment type
• Public cloud

• Private cloud

• Hybrid cloud

Pricing models
Capex and opex(most popular)
• Scale Up

 

• Scale Out
Vertical scaling Horizontal Scaling
• Increase size of instance Add similar type of instances
AWS Global Infrastructure
• Regions –>31 all around the world

AWS has region all around the world


Eg: us-east-1 , us-east-2, ap-south-1,…
A region is a cluster of data centers
Most AWS services are region-scoped
• Availability Zones
• Each region has availability zones
(usually 3, min is 3, max 6)
Eg: ap-south-1a, ap-south-1b, ap-south-1c
• Each AZ’z is one or more discrete data centres with redundant power,
networking and connectivity
• They are separate from each other, so that they’re isolated from
disasters.
• They’re connected with high bandwidth, ultra-low latency networking
AWS point of presence(Edge location)

AWS has 410+ point of presence

Content is delivered to end users with lower latency


Tour of AWS Console
• AWS has global services:
• Identity and Access Management(IAM)
• Route 53 (DNS Service)
• CloudFront (Content Delivery Network)
• WAF (Web Application Firewall)

• AWS Services are Region-Scoped:


• Amazon EC2 (Infrastructure as a Service)
• Elastic BeanStalk (Platform as a Service)
• Lambda (Function as a Service)
• Email, Marketing and Security software (Software as a Service)
How to choose AWS regions

• Compliance:
• Proximity

• Available Services

• Pricing
Access AWS Account
• 1. AWS Management Console

• 2. AWS command Line Interface (CLI)

• 3. Application Programme Interface (API)

• 4. AWS Software Developer Kit (SDK)


Boto3 – AWS python sdk
• Storage
• Persistent
• Non-persistent
Amazon EC2
• EC2 is one of the most popular of AWS’ offering

• EC2 = Elastic Compute Cloud = Infrastructure as a Service


1. Network
2. Storage
`` 3. Server
4. Virtualization
5. Operating System(o/s)
EC2 sizing & configuration options
• Operating System (OS): Linux, Windows or Mac OS
• How much compute power & cores (CPU)
• How much random-access memory (RAM)
• How much storage space:
• Network-attached (EBS & EFS)
• hardware (EC2 Instance Store)
• Network card
• Firewall rules: security group
( Ingress & Egress )
• Bootstrap script (configure at first launch): EC2 User Data
EC2 User Data
• It is possible to bootstrap our instances using an EC2 User data script. •
bootstrapping means launching commands when a machine starts
• That script is only run once at the instance first start
• EC2 user data is used to automate boot tasks such as:
• Installing updates
• Installing software
• Downloading common files from the internet
• Anything you can think of
• The EC2 User Data Script runs with the root user
Bootstrap logs  /var/log/cloud-init-output.log
EC2 Instance Types - Overview
• You can use different types of EC2 instances that are optimised for
different use cases (https://aws.amazon.com/ec2/instance-types/)
• AWS has the following naming convention:
m5.2large

• m: instance class
• 5: generation
• 2xlarge: size within the instance class
EC2 Instance Types
• 1. General purpose
• 2. Compute Optimized
• 3. Memory Optimized
• 4. Accelerated Optimized
• 5. Storage Optimized
• 6. HPC optimized
General Purpose
• • Great for a diversity of workloads such as web servers or code
repositories
• Balance between:
• Compute
• Memory
• Networking

Eg:- Mac, T4g, T3, T3a, T2, M6g, M5, M5a, M5n, M5zn, M4, A1
EC2 Instance Types – Comput Optimized
• Great for compute-intensive tasks that require high performance
processors:
• Batch processing workloads
• Media transcoding
• High performance web servers
• High performance computing (HPC)
• Scientific modelling & machine learning
• Dedicated gaming servers
Eg:- C6g, C6gn, C5, C5a, C5n, C4
EC2 Instance Types – Memory Optimized
• Fast performance for workloads that process large data sets in
memory
• Use cases:
• High performance, relational/non-relational databases
• Distributed web scale cache stores
• In-memory databases optimized for BI (business intelligence)
• Applications performing real-time processing of big unstructured
data
Eg:- R6g, R5, R5a, R5b, R5n, R4, X1e, X1, High memory z1d
EC2 Instance Types – Storage Optimized
• Great for storage-intensive tasks that require high, sequential read and
write access to large data sets on local storage
• Use cases:
• High frequency online transaction processing (OLTP) systems
• Relational & NoSQL databases
• Cache for in-memory databases (for example, Redis)
• Data warehousing applications
• Distributed file systems
Eg: I3, I3en, D2, D3, D3en, H1
Introduction to Security Groups
• Security Groups are the fundamental of network security in AWS
• They control how traffic is allowed in or out of our EC2 Instances.
• Security groups only contain rules
• Security groups rules can reference by IP or by security group
Some point on security groups
• Can be attached to multiple instances
• Locked down to a region vpc combination
• If application is not accessible(time out) , then it’s a security group
issue
• All inbound traffic is blocked by default
• All outbound traffic is authorised by default
Some important ports
• 22 = SSH (Secure Shell) - log into a Linux instance
• 21 = FTP (File Transfer Protocol) – upload files into a file share
• 22 = SFTP (Secure File Transfer Protocol) – upload files using SSH
• 80 = HTTP – access unsecured websites
• 443 = HTTPS – access secured websites
• 3389 = RDP (Remote Desktop Protocol) – log into a Windows instance
3306 = MySQL/Aurora
Amazon EC2 pricing options
• 1). On-demand

• On-demand instances let you pay for compute capacity by the hour or second
(minimum 0f 60 seconds) with no long-term commitments.

• Has the highest cost but no upfront payment

• Recommended for short-term and up-interrupted workloads.


Reserved Instances
• Up to 72% discount compared to On-demand
• You reserve a specific instance attributes (Instance Type, Region,
Tenancy, OS)
• Reservation Period – 1 year (+discount) or 3 years (+++discount)
• Pricing options 
• 1. Full Upfront
• 2. Partial Upfront
• 3. No Upfront ( not for 3 years term )
• Lots of saving in comparison to On-demand.
• You can re-sell on AWS if you choose not to use.
Scheduled reservations
• Available for daily , weekly and monthly.

• Saving as compared to on-demand instances.

• Good for recuring workloads requiring lesser number of hours.

• 1 year term also available.


Spot Instances
• Can get a discount of up to 90% compared to On-demand
• Instances that you can “lose” at any point of time if your max price is less than the current spot
price
• The MOST cost-efficient instances in AWS
• Useful for workloads that are resilient to failure
• Batch jobs
• Data analysis
• Image processing
• Any distributed workloads
• Workloads with a flexible start and end time
• Not suitable for critical jobs or databases.
Rendering
Stateless
EC2 Dedicated Hosts
• A physical server with ec2 instance capacity fully dedicated to your
use
• Purchasing options:
• On-demand  pay per second for active dedicated host
• Reserved  1 tp 3 years (No upfront, partial upfront, all upfront)
• The most expensive option
• Useful for software that have complicated licencing model (BYOL –
Bring Your Own License)
• Or for companies that have strong regulatory or compliance needs
EC2 Dedicated Hosts
• Instances run on hardware that’s dedicated to you

• May share hardware with other instances in same account

• No control over instance placement


• ( can move hardware after stop / start )
5
• curl http://169.254.169.254/latest/meta-data/

• Cloud-config  All cloud accept a script


EC2 Section – Summary
• EC2 Instance: AMI (OS) + Instance Size (CPU + RAM) + Storage +
security groups + EC2 User Data
• Security Groups: Firewall attached to the EC2 instance
• EC2 User Data: Script launched at the first start of an instance
• SSH: start a terminal into our EC2 Instances (port 22)
• EC2 Instance Role: link to IAM roles
• Purchasing Options: On-Demand, Spot, Reserved (Standard +
Convertible + Scheduled), Dedicated Host, Dedicated Instance
• Every AWS account has it’s own limits, you can not use out of limit
type instances or services

• If you want to use then request to AWS to increase the capacity of the
services.

• You can check your limits on EC2 interface limit option.


Placement Group
• A logical grouping of instances with in a single availability zone that
benefit from low network latency, high network throughput.
• Sometimes you want to control using placement groups.
• That strategy can be defined using placement groups
• Three Strategies -->
• 1. Cluster
• 2. Spread
• 3. Partition
• Cluster—clusters instances into a low-latency group in a single
Availability Zone

• Spread—spreads instances across underlying hardware (max 7


instances per group per AZ)
[Reverse of cluster]

• Partition—spreads instances across many different partitions (which


rely on different sets of racks) within an AZ. Scales to 100s of EC2
instances per group.
Private vs Public IP
• Networking has two sorts of IPs. IPv4 and IPv6
• IPv4: 1.160.10.240
• IPv6: 3ffe:1900:4545:3:200:f8ff:fe21:67cf
• IPv4 is still the most common format used online.
• IPv6 is newer and solves problems for the Internet of Things (IoT).
• IPv4 allows for 3.7 billion different addresses in the public space
• IPv4: [0-255].[0-255].[0-255].[0-255].
• Fundamental Difference

• Public IP 
• Public IP means the machine can be identified on the internet.
• Must be unique across the whole web ( not two machines can have the same
public IP).
• Cab be geo-located easily

• Private IP 
• Private IP means the machine can only be identified on a private network only
• The IP must be unique across the private network
• Machines connect to WWW using a NAT + internet gateway (a proxy)
• Only a specified range of IPs can be used as private IP
Elastic IPs
• When you stop and then start an EC2 instance, it can change its public
IP
• If you need to have a fixed public IP for your instance, you need an
Elastic IP
• An Elastic IP is a public IPv4 IP you own as long as you don’t delete it
• You can attach it to one instance at a time
• You can only have 5 Elastic IP in your account (you can ask AWS to
increase that)
Storage
• We have two types of storage 
• 1). DAS (direct attach storage)
• 2). NAS (network attach storage)
• A). Block Storage
• B). File storage
• C). Object storage
• Block storage – technology that controls data storage and storage
devices. [ SAN – storage area network (block level access) ]
• Hard disk – block storage device, when we format this device (file
system) . It divide in different block.
• Block storage – high speed internet connectivity mandatory
• EBS volume and instance on the same zone.
• Drawback  1). At running time attach with only one instance.
2). AZs of EBS and machine same mandatory

Persistent Storage  Any data storage device that retains(to keep or


continue) data after power to that device is shut off.
• File Storage :
• A method of storing data in the cloud that provides servers and
applications access to data through shared file systems. This
compatibility makes cloud file storage ideals for workloads that
rely on shared file system and provides simple integration
without code changes.
• File level access – NAS (network attach storage)
• NAS  dedicated file storage that enables multiple users and
heterogeneous client devices to retrieve data from centralized
disk capacity. Users on a local area network(LAN) access the
shared storage via a standard ethernet connection.
• Object Storage 
• A technology that stores and management data in an
unstructured format called objects.
• Modern organizations create and analyse large volumes
of unstructured data such as photos, videos, email, web
pages, sensor data and audio files.
• AWS object storage service  S3(simple storage service)
EBS (Elastic Block Storage)
• A network drive you can attach to your instances when they are in
running state.
• And it allows your instances to persist data, even after their
termination
• We can use after mount and file system
• Must be same availability zones of instance and volume.
EBS steps 
• 1). Volume type
• 2). Size
• 3). IOPS
• 4). Throughput
• 5). Availability zones
• 6). Snapshot
• 7). Encryption
• 8). Tags
Snapshot
• EBS snapshots are a point-in-time copy of your data, and can be used
to enable disaster recovery, migrating data across regions and
accounts, and improve backup compliance.
• Make a backup of your EBS volume at a point in time
• We can copy snapshots across AZ or region

• EBS snapshot features 


• EBS Snapshot Archive:
• Move snapshot to an archive tier that is 75% cheaper
• Recycle bin for EBS Snapshots:
• Setup rules to retain deleted snapshot so you can recover them after an accident
deletion

• Fast Snapshot Restore (FSR)


• Force full initialization of snapshot to have no latency on the first
EBS Volume Types
• EBS Volumes come in 6 type
• gp2 / gp3 (SSD): General purpose SSD volume that balances price and
performance for a wide variety of workloads
• io1 / io2 (SSD): Highest-performance SSD volume for mission-critical low-
latency or high-throughput workloads
• st1 (HDD): Low cost HDD volume designed for frequently accessed,
throughput- intensive workload
• sc1 (HDD): Lowest cost HDD volume designed for less frequently accessed
workloads
• Only gp2/gp3 and io1/io2 can be used as boot volumes
Amazon Machine Image(AMI)
• AMI are a customization of an ec2 instance
• You add your own software, configuration, operating system ,monitoring.
• Faster boot/configuration time because all your software is pre-packaged.
• AMI are built for a specific region and can be copied across regions
• You can launch instances from:
• A public AMI – AWS provided
• Your own AMI – You make and maintain them yourself
• An AWS marketplace AMI – An AMI someone else mode and potentially sells
AMI process
• From an EC2 instance

• Start an EC2 instance and customize it


• Stop the instance
• Build an AMI – this will also create EBS snapshots
• Launch instance from another AMIs
EFS (Elastic File System)
• Managed NFS(Network File System) that can be mounted on many EC2
• EC2 works with EC2 instances in multi-AZ
• Highly available , scalable , expensive (3x gp2) , pay per use
• Use security group to control to EFS
• Compatible with Linux based AMI(not for window)
• Uses NFS version 4.1
• File system scales automatically, pay-per-use, no capacity planning
• Database server not on EFS because of latency.
EFS – performance and storage classes
• EFS scale 

• Performance Mode (set at EFS creation time)


• General purpose – latency-sensitive use cases
• Man i/o – higher latency, throughput, highly parallel

• Throughput Mode
• Bursting –
• Provisioned –
• Elastic –
How to create EFS 
• Create file system
• Name
• Availability and durability
• Regional / standard
• One zone
• Automatic backups
• Lifecycle Management
• Transition into IA Transition out of IA
• Pricing difference up to 70-80%
• Encryption
• Throughput mode
• Bursting - standard
• Enhanced -

• Network Access
• Here we can select the mount targets

• Review
• Create
How to use EFS
• Click on the EFS – Attach ( to check how we can mount this on our
machine )
• Install amazon-efs-utils in machine to mount EFS.
• Make directory to mount
• Add security group to the EFS

• Now simply select the command and paste


EBS vs EFS
• EBS volumes 
• One instance at a time
• Looked at the availability zone level
• Gp2:IO increase if the disk size increases
• Io:I can increase IO independently
• To migrate an EBS volume to another availability zone
• Take a snapshot
• Restore the snapshot to another availability zone
• EBS backups use IO and you shouldn’t run them while your application is handling a lot of
traffic.
• Root EBS volumes of instances get terminated by default if the EC2
instance gets terminated.
EBS and EFS
• Mounting 100s of instances across availability zones
• EFS share website files (wordpress)
• Only for linux instances
• EFS has a higher price point than EBS
• Can leverage EFS-IA for cost savings

• Remember: EBS vs EFS vs Instance store


Load Balancer
• Load balancer are servers that forward traffic to multiple servers
downstream


Use of load balancer
• Spread load across multiple downstream instances
• Expose a single point of access to your application
• Do regular health check on your website
• Provide SSL termination for your websites
• High availability across zones
• Sperate public traffic from private traffic
ENI (Elastic Network Interface)
• Aws ENI or network interface are virtual network cards attached to
EC2 instances that help facilitate network connectivity for instances.
• Having two or more AWS network interface connected to an instance
permits it to communicate on two separate subnets.
• One ENI lives in only one subnet means single availability zones.
EFA (Elastic Fabric Adapter)
• EFA is a network interface for Amazon EC2 instances that enables
customers to run applications requiring high levels of inter-node
communications at scale on AWS.
ENA (Elastic Network Adaptor)
• To enhance the speed of network
• A custom network interface optimized to deliver high throughput and
packet per second(PPS) performance, and consistently low latencies
on EC2 instance.

You might also like