AWS EC2

官网:https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/InstanceStorage.html

What Is Amazon EC2?

Amazon Elastic Compute Cloud (Amazon EC2) provides scalable computing capacity in the Amazon Web Services (AWS) cloud. Using Amazon EC2 eliminates your need to invest in hardware up front, so you can develop and deploy applications faster. You can use Amazon EC2 to launch as many or as few virtual servers as you need, configure security and networking, and manage storage. Amazon EC2 enables you to scale up or down to handle changes in requirements or spikes in popularity, reducing your need to forecast traffic.

Features of Amazon EC2

Amazon EC2 provides the following features:

  • Virtual computing environments, known as instances

  • Preconfigured templates for your instances, known as Amazon Machine Images (AMIs), that package the bits you need for your server (including the operating system and additional software)

  • Various configurations of CPU, memory, storage, and networking capacity for your instances, known as instance types

  • Secure login information for your instances using key pairs (AWS stores the public key, and you store the private key in a secure place)

  • Storage volumes for temporary data that's deleted when you stop or terminate your instance, known as instance store volumes

  • Persistent storage volumes for your data using Amazon Elastic Block Store (Amazon EBS), known as Amazon EBS volumes

  • Multiple physical locations for your resources, such as instances and Amazon EBS volumes, known as regions and Availability Zones

  • A firewall that enables you to specify the protocols, ports, and source IP ranges that can reach your instances using security groups

  • Static IPv4 addresses for dynamic cloud computing, known as Elastic IP addresses

  • Metadata, known as tags, that you can create and assign to your Amazon EC2 resources

  • Virtual networks you can create that are logically isolated from the rest of the AWS cloud, and that you can optionally connect to your own network, known as virtual private clouds(VPCs)


    EC2的关键词在于可伸缩,需要多少个instance,可以在短时间内建成不需要的时候可以立刻terminate。

    instance相当于虚拟机,也相当于virtual box的一个窗口。

    AMI包括操作系统,其他软体

    instance type 在这选择多种cpu,内存,储存空间,网络性能

    instance store volumes,每个新建的instance,数据都会暂时保存在instance store volumes里面。stop或terminate instance1之后,instance store上存储的instance1的数据会消失。

    通常建一个instance流程

    选择images->新建instance->选择instance type->metadata->建成


Amazon EC2 Instance Store

An instance store provides temporary block-level storage for your instance. This storage is located on disks that are physically attached to the host computer. Instance store is ideal for temporary storage of information that changes frequently, such as buffers, caches, scratch data, and other temporary content, or for data that is replicated across a fleet of instances, such as a load-balanced pool of web servers.

An instance store consists of one or more instance store volumes exposed as block devices. The size of an instance store as well as the number of devices available varies by instance type. While an instance store is dedicated to a particular instance, the disk subsystem is shared among instances on a host computer.

The virtual devices for instance store volumes are ephemeral[0-23]. Instance types that support one instance store volume have ephemeral0. Instance types that support two instance store volumes have ephemeral0 and ephemeral1, and so on.

Amazon EC2 instance storage

Instance Store Lifetime

You can specify instance store volumes for an instance only when you launch it. You can't detach an instance store volume from one instance and attach it to a different instance.

The data in an instance store persists only during the lifetime of its associated instance. If an instance reboots (intentionally or unintentionally), data in the instance store persists. However, data in the instance store is lost under any of the following circumstances:

  • The underlying disk drive fails

  • The instance stops

  • The instance terminates

Therefore, do not rely on instance store for valuable, long-term data. Instead, use more durable data storage, such as Amazon S3, Amazon EBS, or Amazon EFS.

When you stop or terminate an instance, every block of storage in the instance store is reset. Therefore, your data cannot be accessed through the instance store of another instance.

If you create an AMI from an instance, the data on its instance store volumes isn't preserved and isn't present on the instance store volumes of the instances that you launch from the AMI.

Instance Store Volumes

The instance type determines the size of the instance store available and the type of hardware used for the instance store volumes. Instance store volumes are included as part of the instance's usage cost. You must specify the instance store volumes that you'd like to use when you launch the instance (except for NVMe instance store volumes, which are available by default). Then format and mount the instance store volumes before using them. You can't make an instance store volume available after you launch the instance. For more information, see Add Instance Store Volumes to Your EC2 Instance.

Some instance types use NVMe or SATA-based solid state drives (SSD) to deliver high random I/O performance. This is a good option when you need storage with very low latency, but you don't need the data to persist when the instance terminates or you can take advantage of fault-tolerant architectures. For more information, see SSD Instance Store Volumes.

The following table provides the quantity, size, type, and performance optimizations of instance store volumes available on each supported instance type. For a complete list of instance types, including EBS-only types, see Amazon EC2 Instance Types.

Instance Type Instance Store Volumes Type Needs Initialization* TRIM Support**

c1.medium

1 x 350 GB†

HDD  

c1.xlarge

4 x 420 GB (1,680 GB)

HDD  

c3.large

2 x 16 GB (32 GB)

SSD  

c3.xlarge

2 x 40 GB (80 GB)

SSD  

c3.2xlarge

2 x 80 GB (160 GB)

SSD  

c3.4xlarge

2 x 160 GB (320 GB)

SSD  

c3.8xlarge

2 x 320 GB (640 GB)

SSD  
c5d.large 1 x 50 GB  NVMe SSD  
c5d.xlarge 1 x 100 GB NVMe SSD  
c5d.2xlarge 1 x 200 GB NVMe SSD  
c5d.4xlarge 1 x 400 GB NVMe SSD  
c5d.9xlarge 1 x 900 GB NVMe SSD  
c5d.18xlarge 2 x 900 GB (1.8 TB) NVMe SSD  

cc2.8xlarge

4 x 840 GB (3,360 GB)

HDD  

cr1.8xlarge

2 x 120 GB (240 GB)

SSD  

d2.xlarge

3 x 2,000 GB (6 TB)

HDD    

d2.2xlarge

6 x 2,000 GB (12 TB)

HDD    

d2.4xlarge

12 x 2,000 GB (24 TB)

HDD    

d2.8xlarge

24 x 2,000 GB (48 TB)

HDD    

f1.2xlarge

1 x 470 GB

NVMe SSD  

f1.16xlarge

4 x 940 GB

NVMe SSD  
g2.2xlarge 1 x 60 GB SSD  
g2.8xlarge 2 x 120 GB (240 GB) SSD  
h1.2xlarge 1 x 2000 GB (2 TB) HDD    
h1.4xlarge 2 x 2000 GB (4 TB) HDD    
h1.8xlarge 4 x 2000 GB (8 TB) HDD    
h1.16xlarge 8 x 2000 GB (16 TB) HDD    

hs1.8xlarge

24 x 2,000 GB (48 TB)

HDD  

i2.xlarge

1 x 800 GB

SSD  

i2.2xlarge

2 x 800 GB (1,600 GB)

SSD  

i2.4xlarge

4 x 800 GB (3,200 GB)

SSD  

i2.8xlarge

8 x 800 GB (6,400 GB)

SSD  

i3.large

1 x 475 GB

NVMe SSD  

i3.xlarge

1 x 950 GB

NVMe SSD  

i3.2xlarge

1 x 1,900 GB

NVMe SSD  

i3.4xlarge

2 x 1,900 GB (3.8 TB)

NVMe SSD  

i3.8xlarge

4 x 1,900 GB (7.6 TB)

NVMe SSD  

i3.16xlarge

8 x 1,900 GB (15.2 TB)

NVMe SSD  

i3.metal

8 x 1,900 GB (15.2 TB)

NVMe SSD  

m1.small

1 x 160 GB†

HDD  

m1.medium

1 x 410 GB

HDD  

m1.large

2 x 420 GB (840 GB)

HDD  

m1.xlarge

4 x 420 GB (1,680 GB)

HDD  

m2.xlarge

1 x 420 GB

HDD  

m2.2xlarge

1 x 850 GB

HDD  

m2.4xlarge

2 x 840 GB (1,680 GB)

HDD  

m3.medium

1 x 4 GB

SSD  

m3.large

1 x 32 GB

SSD  

m3.xlarge

2 x 40 GB (80 GB)

SSD  

m3.2xlarge

2 x 80 GB (160 GB)

SSD  
m5d.large 1 x 75 GB  NVMe SSD  
m5d.xlarge 1 x 150 GB NVMe SSD  
m5d.2xlarge 1 x 300 GB NVMe SSD  
m5d.4xlarge 2 x 300 GB NVMe SSD  
m5d.12xlarge 2 x 900 GB NVMe SSD  
m5d.24xlarge 4 x 900 GB (3.6 TB) NVMe SSD  

r3.large

1 x 32 GB

SSD  

r3.xlarge

1 x 80 GB

SSD  

r3.2xlarge

1 x 160 GB

SSD  

r3.4xlarge

1 x 320 GB

SSD  

r3.8xlarge

2 x 320 GB (640 GB)

SSD  

x1.16xlarge

1 x 1,920 GB

SSD    

x1.32xlarge

2 x 1,920 GB (3,840 GB)

SSD    

x1e.xlarge

1 x 120 GB

SSD    

x1e.2xlarge

1 x 240 GB

SSD    

x1e.4xlarge

1 x 480 GB

SSD    

x1e.8xlarge

1 x 960 GB

SSD    

x1e.16xlarge

1 x 1,920 GB

SSD    

x1e.32xlarge

2 x 1,920 GB (3,840 GB)

SSD    

* Volumes attached to certain instances suffer a first-write penalty unless initialized. For more information, see Optimizing Disk Performance for Instance Store Volumes.

** For more information, see Instance Store Volume TRIM Support.

† The c1.medium and m1.small instance types also include a 900 MB instance store swap volume, which may not be automatically enabled at boot time. For more information, see Instance Store Swap Volumes.




猜你喜欢

转载自blog.csdn.net/weixin_29228233/article/details/80983091