Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to specify the rack location policy for EC2 instances in AWS

2025-02-21 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)05/31 Report--

This article shows you how to specify the rack location strategy of EC2 instances in AWS. The content is concise and easy to understand, which will definitely brighten your eyes. I hope you can get something through the detailed introduction of this article.

Today we introduce AWS placement group knowledge points.

When we start the EC2 instance, the EC2 service will try to place the instance in some way to distribute all the instances on the underlying hardware to minimize related failures. AWS has default placement rules, which can meet most of the usage requirements by default.

But what if we want to place the EC2 we launched as close to each other in the same availability zone as possible to achieve low latency network performance, or to place some instances strictly on different hardware to reduce related failures? Can it be realized? Of course, you can use the placement group of AWS described in this article. Depending on the workload type, you can create a placement group using one of the following placement strategies:

Cluster-packages close instances in an availability zone together. By using this strategy, workloads can achieve the required low-latency network performance to meet the tightly coupled node-to-node communication requirements commonly used by HPC applications.

Partitions-distribute instances on different logical partitions * so that instance groups in one partition do not use the same underlying hardware as instance groups in different partitions. * this strategy is typically used by large distributed and repetitive workloads, such as Hadoop, Cassandra, and Kafka.

Distribution-A small number of instances are strictly placed on different underlying hardware to reduce related failures.

The following picture shows my own placement group, with 1 cluster / partition / distribution each.

Next, we will introduce three placement strategies:

Cluster placement group

A cluster placement group is a logical grouping of instances in a single availability zone. According to the official data of AWS, all nodes in the placement group can communicate with all other nodes in the placement group at a full-line rate of 10 Gpbs streams and 25 aggregations without any deceleration due to oversubscription.

The following figure shows an example placed in a cluster placement group.

Cluster placement group is to put the launched EC2 instances together as far as possible-the same cabinet or adjacent cabinets to reduce the physical distance between instances. It is generally used for applications that benefit from low network latency and / or high network throughput, and it is recommended to use cluster placement groups when most of the network traffic is between the instances in the group.

Partition placement group

When placing groups using partitions, Amazon EC2 divides each group into logical segments (called "partitions"). Amazon EC2 ensures that each partition in the placement group has its own set of racks. Each rack has its own network and power supply. Any two partitions in the placement group will not share the same rack, allowing you to isolate the effects of hardware failures in your application.

The following figure is a simple visual representation of a partition placement group in a single availability zone. It shows an instance of placement into a partition placement group with three partitions-* Partition 1 *, * Partition 2 * and * Partition 3. Each partition contains multiple instances. Instances in one partition do not share racks with instances in other partitions, which allows you to limit the impact of a single hardware failure to the relevant partition.

Large distributed and repetitive workloads, such as HDFS, HBase, and Cassandra, can be deployed across different racks using partitioned placement groups. When you start an instance in a partition placement group, Amazon EC2 attempts to distribute the instance evenly across the number of partitions you specify. You can also start the instance in a specific partition to better control where the instance is placed.

A partition placement group can have partitions in multiple availability zones in the same area. For each availability zone, a partition placement group can have up to 7 partitions.

Distributed placement group

Distributed placement groups can place each instance on a different rack, and each rack has its own network and power supply.

The following figure shows seven instances in a single availability zone that have been placed into a distributed placement group. Seven instances are placed on seven different racks.

It is recommended that you use distributed placement groups in applications with a small number of important instances that should be placed separately. By starting an instance in a distributed placement group, you can reduce the risk of simultaneous failure when the instance has the same rack. Distributed placement groups can access different racks, so it is suitable to mix different types of instances or start instances over time.

Distributed placement groups can span multiple availability zones in the same area. Each group has up to 7 running instances in each availability zone.

Above, the content of the placement group is over, so how to put the EC2 instance into the group?

In the configuration instance step of starting the EC2 instance, you can choose to add the EC2 instance to the placement group, so that the EC2 instance is in the placement group.

The above content is how to specify the rack location strategy for EC2 instances in AWS. Have you learned any knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report