# Elastic Compute Cloud

### Regional and Global AWS Architecture <a href="#lecture_heading" id="lecture_heading"></a>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FcPuzdzuGWewgExJKXe1s%2Fimage.png?alt=media&#x26;token=2ec25184-3a84-4d89-be10-54b5a8751998" alt=""><figcaption></figcaption></figure>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2F3hKJgI8CVxfg4Ns1VK9n%2Fimage.png?alt=media&#x26;token=9896d147-c37e-49eb-9059-1d94d09903bc" alt=""><figcaption></figcaption></figure>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FIZetcWPFYkvVmDqkKHMB%2Fimage.png?alt=media&#x26;token=a152fa14-b762-4db2-988e-0a76df641d70" alt=""><figcaption></figcaption></figure>

### Purchase Options

#### On-Demand

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FiZw6f6dMfO4lEVg9BDhe%2Fimage.png?alt=media&#x26;token=3be575a4-a46e-4644-9ce1-0fd92703e806" alt=""><figcaption></figcaption></figure>

#### Spot

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FJvjJU4TY8tU6CsxgyQEV%2Fimage.png?alt=media&#x26;token=2830aa36-459f-472a-a6b5-0bf24a02f8d5" alt=""><figcaption></figcaption></figure>

Reserved

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FQ8PCLBOoL0ncx5FXf0E9%2Fimage.png?alt=media&#x26;token=80a4473e-6f49-4319-8ad4-aec8a5c26f44" alt=""><figcaption></figcaption></figure>

Dedicated Instance

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FW7jgBYgj0oGF1tyvB4w9%2Fimage.png?alt=media&#x26;token=f61835f1-bb9f-414d-b719-fc680ea07b8e" alt=""><figcaption></figcaption></figure>

Dedicated Host

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FyiwR6B2owlyaWS9D0r2D%2Fimage.png?alt=media&#x26;token=be5f1b03-12e1-4a61-8531-d491848ccc92" alt=""><figcaption></figcaption></figure>

#### Scheduled Reserved Instances

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FZ2Db4SfYt0iqpzptioxz%2Fimage.png?alt=media&#x26;token=eff20517-88ae-4b91-a721-724a49774d6a" alt=""><figcaption></figcaption></figure>

#### Capacity Reservations

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2F7jKKVFuhyLqYTKJCy1hs%2Fimage.png?alt=media&#x26;token=f76f989d-e560-4388-aab5-bebb7245b707" alt=""><figcaption></figcaption></figure>

#### EC2 Savings Plan

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FH3yl3InwmwaKy2iWJxDh%2Fimage.png?alt=media&#x26;token=28320bb5-e06d-4f40-a7e5-15c41eb89b8a" alt=""><figcaption></figcaption></figure>

### Networking

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FUKrjIka4b8sxbSlGS5Sm%2Fimage.png?alt=media&#x26;token=ea813373-f5ea-4aef-bbc1-2c3cad972fff" alt=""><figcaption></figcaption></figure>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2F2PadhZcNROS5IGW9Jlft%2Fimage.png?alt=media&#x26;token=c11c5ac5-e611-416b-8501-012c17685779" alt=""><figcaption></figcaption></figure>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FvpsE4M5tPLsF7jau9918%2Fimage.png?alt=media&#x26;token=a26ffbb6-0cd7-4ab0-9831-753ffb1d910c" alt=""><figcaption></figcaption></figure>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FjflDyDTys0qsPmhJf9o9%2Fimage.png?alt=media&#x26;token=c19bddf4-052d-4d4a-b5a2-231ba393eff8" alt=""><figcaption></figcaption></figure>

### Bootstrapping vs AMI Baking <a href="#lecture_heading" id="lecture_heading"></a>

**What does 'Complete' mean**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FJKTYyYxpDAGTFFx5oLgT%2Fimage.png?alt=media&#x26;token=0e493d1a-c526-4bae-8174-b7bcda73c9c6" alt=""><figcaption></figcaption></figure>

**Ready For Service Lag**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FefBcxVrPIUjJ8JlqYzPh%2Fimage.png?alt=media&#x26;token=abd8cd84-d956-41e9-a6bc-bcb3850042f3" alt=""><figcaption></figcaption></figure>

**Application Installation Architecture**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FyVqaEC2XCQORueYcLuGB%2Fimage.png?alt=media&#x26;token=7ee10d26-b2ec-4ad4-b2f9-8c1d034ae821" alt=""><figcaption></figcaption></figure>

**Bootstrapping**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FYRYK97H5Sdtq1PBV59zW%2Fimage.png?alt=media&#x26;token=43154df7-6e7a-4583-82e3-ffd53754d350" alt=""><figcaption></figcaption></figure>

**AMI Baking**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FoUBeyyURONDVU9jmNUPA%2Fimage.png?alt=media&#x26;token=4c830d25-14ee-4ff4-8bd9-1cb210897e8c" alt=""><figcaption></figcaption></figure>

**You can use a combination....**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2Fto4ktHw1u33B67FysZIK%2Fimage.png?alt=media&#x26;token=229d29a6-52a2-4ca2-b03d-856b5943e772" alt=""><figcaption></figcaption></figure>

### Placement Groups <a href="#lecture_heading" id="lecture_heading"></a>

When you launch a new EC2 instance, the EC2 service attempts to place the instance in such a way that all of your instances are spread out across underlying hardware to minimize correlated failures. You can use _placement groups_ to influence the placement of a group of _interdependent_ instances to meet the needs of your workload. Depending on the type of workload, you can create a placement group using one of the following placement strategies:

* _Cluster_ – packs instances close together inside an Availability Zone. This strategy enables workloads to achieve the low-latency network performance necessary for tightly-coupled node-to-node communication that is typical of HPC applications.
* _Partition_ – spreads your instances across logical partitions such that groups of instances in one partition do not share the underlying hardware with groups of instances in different partitions. This strategy is typically used by large distributed and replicated workloads, such as Hadoop, Cassandra, and Kafka.
* _Spread_ – strictly places a small group of instances across distinct underlying hardware to reduce correlated failures.

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FccQcGrtIKnsqUkgzaDOP%2Fimage.png?alt=media&#x26;token=e849f7d0-12a6-41d6-ba60-764229470dd7" alt=""><figcaption></figcaption></figure>

**Cluster Placement Groups**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FmngvjSyII1ccYDml4iWm%2Fimage.png?alt=media&#x26;token=88f39f7b-53ac-4c5e-a2c7-aea4bc888943" alt=""><figcaption></figcaption></figure>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FFBBFDP6ygj6euo3fB59C%2Fimage.png?alt=media&#x26;token=b2d2b256-bdd0-4a9e-8f78-bef53d713dcb" alt=""><figcaption></figcaption></figure>

**Spread Placement Groups**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FXSPSZ4bZ5pVUl5ArxIX3%2Fimage.png?alt=media&#x26;token=e6649ea4-b259-496f-baf9-eb1182e3778f" alt=""><figcaption></figcaption></figure>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FAE7kAFR1I2bnCGJ13OJV%2Fimage.png?alt=media&#x26;token=bc91e935-3f4c-4c94-8788-79b4d6ffd5fd" alt=""><figcaption></figcaption></figure>

**Partition Placement Groups**

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FaTbAap7rFW5nszgx2iHw%2Fimage.png?alt=media&#x26;token=f0039cfa-5bf6-4ba3-85e5-3a09d0aefa02" alt=""><figcaption></figcaption></figure>

<figure><img src="https://42327672-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRTgPcl2FlnhXAydvRoXO%2Fuploads%2FWADZLg9CAeeBAcLeEnsy%2Fimage.png?alt=media&#x26;token=57c37a06-c1c5-46d2-9348-16b122df0346" alt=""><figcaption></figcaption></figure>
