Spotinst raises $15M Series A Led By Intel Capital and Vertex Ventures Read The Official Press Release

Placement Group Support

Amiram Shachar
Spotinst, Founder and CEO

We are very excited to announce EC2 Placement Group support for our Elastigroup product allowing our customers to enhance their application network performances.
Placement Group is a logical grouping of instances within a single Availability Zone. Placement groups are recommended for applications that benefit from low network latency, high network throughput, such as Hadoop, Spark, Druid and more.

When you provision instances into a Placement group, AWS automatically tries to find a rack that can handle the entire placement group for a better network connection between the instances, therefore it is recommended to use instances that support enhanced networking. In some cases AWS fails to find the required capacity, in this situation, Elastigroup will automatically take over and will perform recovery (Elastigroup will start the instances outside of the placement group).

Best Practices

  1. Try to use the same instance type or as similar as possible.
    When using different instance types for placement group’s members, the chances to find proper allocation decreases and most likely the request will fail with the error “Insufficient Capacity”, in this case, Elastigroup’s recovery will take place.
  2. Maximum network throughput speed of traffic between two instances in a placement group is limited by the slower of the two instances. For applications with high-throughput requirements, choose an instance type with 10 Gbps or 20 Gbps network connectivity.

Things to Consider

  1. Placement Group cannot be distributed across Availability Zones
    (All the associated members must be of the same Availability Zone)
  2. Instance types supported for placement are limited, Supported Instance Type:
  • General purpose:  m4.large | m4.xlarge | m4.2xlarge | m4.4xlarge | m4.10xlarge | m4.16xlarge
  • Compute-optimized:  c4.large | c4.xlarge | c4.2xlarge | c4.4xlarge | c4.8xlarge | c3.large | c3.xlarge | c3.2xlarge | c3.4xlarge | c3.8xlarge | cc2.8xlarge
  • Memory optimized:  cr1.8xlarge | r3.large | r3.xlarge | r3.2xlarge | r3.4xlarge | r3.8xlarge| r4.large | r4.xlarge | r4.2xlarge | r4.4xlarge | r4.8xlarge | r4.16xlarge | x1.16xlarge | x1.32xlarge
  • Storage optimized:  d2.xlarge | d2.2xlarge | d2.4xlarge | d2.8xlarge | hi1.4xlarge | hs1.8xlarge | i2.xlarge | i2.2xlarge | i2.4xlarge | i2.8xlarge | i3.large | i3.xlarge | i3.2xlarge | i3.4xlarge | i3.8xlarge | i3.16xlarge
  • Accelerated computing:  cg1.4xlarge | f1.2xlarge | f1.16xlarge | g2.2xlarge | g2.8xlarge | p2.xlarge | p2.8xlarge | p2.16xlarge

3. You can’t associate an existing instance into a placement group. You must create a new instance in the placement group.

4. Capacity reservation (via Reserved instances) can be used by instances in a placement group that is assigned to the same Availability Zone. However, it is not possible to explicitly reserve capacity for a placement group.

5. Members of the placement group must address each other via their private IP addresses.

6. When using on-demand instances, if you stop and then start an instance, in some cases AWS will fail to find the required capacity causing the Elastigroup.

Elastigroup Configurations

  1. Set up a Placement Group on your AWS account in the relevant Availability Zone, prior of adding it to an ElastiGroup
  2. Use the UI or the API to assign the Placement group to an ElastiGroup

A. Using the UI:

  • Open the Elastigroup where you wish to add the Placement Group
  • Click on the Actions menu
  • Select “Edit Configuration”
  • Navigate to the “Review” Tab from the top navigation bar     screen-shot-2017-05-22-at-11-35-28-am
  • Enable “Edit Mode” and add the placementGroupName property to the relevant Availability zone setting:
  "availabilityZones": [
    {
      "name": "us-west-2b",
      "placementGroupName": "Your_Placement_Group",
      "subnetIds": [
        "subnet-1234567"
      ]
    }
  ]

Note: The Placement group name is case-sensitive

B. Using the API:

  • Use the Update or Create API as listed here: Create API, Update API
  • In the case of creating a group, add the “placementGroupName” to the Availability zone setting.
  • In the case of updating a group, use the following Body in your request:

 

  "availabilityZones": [
    {
      "name": "us-west-2b",
      "placementGroupName": "Your_Placement_Group",
      "subnetIds": [
        "subnet-1234567"
      ]
    }
  ]

Note: The Placement group name is case-sensitive
Find here additional information about Placement Groups

Amiram Shachar
Spotinst, Founder and CEO

Stay current

Sign up for our newsletter, and we'll send you the latest updates on Spotinst, tips, tutorials and more cool stuff!