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.
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html
É um grupo lógico de instâncias em uma zona de disponibilidade, este tipo de placement é recomendado em situações onde a maior parte do tráfego de rede ocorre entre as instâncias do grupo, desta forma as instâncias se beneficiam de uma baixa latência de rede.
É recomendado que as instâncias de um cluster placement group sejam criadas em uma única requisição e utilizem o mesmo tipo de instância evitando possíveis capacity errors.
A cluster placement group is a logical grouping of instances within a single Availability Zone. Cluster placement groups are recommended for applications that benefit from low network latency, high network throughput, or both. They are also recommended when the majority of the network traffic is between the instances in the group. To provide the lowest latency and the highest packet-per-second network performance for your placement group, choose an instance type that supports enhanced networking.
We recommend that you launch your instances in the following way:
- Use a single launch request to launch the number of instances that you need in the placement group.
- Use the same instance type for all instances in the placement group.
If you try to add more instances to the placement group later, or if you try to launch more than one instance type in the placement group, you increase your chances of getting an insufficient capacity error.
If you stop an instance in a placement group and then start it again, it still runs in the placement group. However, the start fails if there isn't enough capacity for the instance.
If you receive a capacity error when launching an instance in a placement group that already has running instances, stop and start all of the instances in the placement group, and try the launch again. Starting the instances may migrate them to hardware that has capacity for all of the requested instances.
Partition placement groups são grupos de instâncias encapsulados por um objeto lógico chamado partição distribuído em diferentes zonas de disponibilidade na mesma região. Cada partição dentro de um placement group possui seu próprio conjunto de racks e cada rack possui sua própria rede e fonte de energia. Partition placement groups são utilizados no deploy de sistemas distribuídos e replicados. O serviço EC2 tentará distribuir as instâncias criadas no partition placement group de maneira uniforme de acordo com a quantidade de partições definidas.
Partition placement groups help reduce the likelihood(probabilidade) of correlated hardware failures for your application. When using partition placement groups, Amazon EC2 divides each group into logical segments called partitions. Amazon EC2 ensures that each partition within a placement group has its own set of racks. Each rack has its own network and power source, allowing you to isolate the impact of hardware failure within your application.
Partition placement groups can be used to deploy large distributed and replicated workloads across distinct racks. When you launch instances into a partition placement group, Amazon EC2 tries to distribute the instances evenly across the number of partitions that you specify. You can also launch instances into a specific partition.
A partition placement group can have partitions in multiple Availability Zones in the same Region. A partition placement group can have a maximum of seven partitions per Availability Zone. The number of instances that can be launched into a partition placement group is limited only by the limits of your account.
In addition, partition placement groups offer visibility into the partitions — you can see which instances are in which partitions. You can share this information with topology-aware applications, these applications use this information to make intelligent data replication decisions for increasing data availability and durability.
Um spread placement group é um grupo de instâncias dispostas em racks distintos onde cada rack possui sua própria rede e fonte de energia.
A spread placement group is a group of instances that are each placed on distinct racks, with each rack having its own network and power source.
Spread placement groups are recommended for applications that have a small number of critical instances that should be kept separate from each other. Launching instances in a spread placement group reduces the risk of simultaneous failures that might occur when instances share the same racks. Spread placement groups provide access to distinct racks, and are therefore suitable for mixing instance types or launching instances over time.
A spread placement group can span multiple Availability Zones in the same Region. You can have a maximum of seven running instances per Availability Zone per group.