Resize – EC2 Resources

Posted By:insisivecloud
Posted on:09 Sep 2019
AWS

Introduction:

As per application needs, you may need to resize or add your instances to an auto-scaling group. In this post, we will go through the prerequisites that need to be met before resizing your EC2 Instances.

Factors that lead to Resizing:

  • Underutilization of EC2 instances
  • Overutilization of EC2 instances
  • Upgrade to a new generation instance types that have better price /performance ratio

Compatibility factors that need to be checked before Resizing:

  • Virtualization Type
  • Architecture
  • Network
  • Enhancing Networking
  • NVMe
  • AMI

There are different types of Instances family provided by AWS like General Purpose, Compute Optimized, Storage Optimized, Memory Optimized, and Nitro Based. So, you need to be careful while moving from one family to another.

Instructions:

For example, prerequisites that need to be followed for any Nitro Based Instances

  • Verify whether ENA enabled to your Instance.
  • Validate whether ENA drivers were installed.
  • Validate whether NVMe drivers were installed.
  • Make sure entries in fstab file were with UUID instead of device volume name.

Note: Nitro Based Instances are
A1, C5, C5d, C5n, I3en, M5, M5a, M5ad, M5d,p3dn.24xlarge, R5, R5a, R5ad, R5d, T3, T3a, and z1d

Bare metal: c5.metal, c5n.metal, i3.metal, i3en.metal, m5.metal, m5d.metal, r5.metal, r5d.metal, u-6tb1.metal, u-9tb1.metal, u-12tb1.metal and z1d.metal 

AWS Provides a script to validate whether your current Instances met the prerequisites of your new instances.

Script Location:
https://github.com/awslabs/aws-support-tools/blob/master/EC2/C5M5InstanceChecks/c5_m5_checks_script.sh

It will support only for below OS:

  • RedHat derivatives
  • Amazon Linux, Amazon Linux 2
  • Debian derivatives

It will help to install the drivers and modify the fstab file.

Reference Link:

https://aws.amazon.com/premiumsupport/knowledge-center/boot-error-linux-m5-c5/

https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-resize.html

https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html#instance-hardware-specs