Compute optimized instances - Amazon Elastic Compute Cloud
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Compute optimized instances

Note

For detailed instance type specifications, see the Amazon EC2 Instance Types Guide. For pricing information, see Amazon EC2 Instance Types.

Compute optimized instances are ideal for compute-bound applications that benefit from high-performance processors.

C5 and C5n instances

These instances are well suited for the following:

  • Batch processing workloads

  • Media transcoding

  • High-performance web servers

  • High-performance computing (HPC)

  • Scientific modeling

  • Dedicated gaming servers and ad serving engines

  • Machine learning inference and other compute-intensive applications

Bare metal instances, such as c5.metal, provide your applications with direct access to physical resources of the host server, such as processors and memory.

C6g, C6gd, and C6gn instances

These instances are powered by Amazon Graviton2 processors and are ideal for running advanced, compute-intensive workloads, such as the following:

  • High-performance computing (HPC)

  • Batch processing

  • Ad serving

  • Video encoding

  • Gaming servers

  • Scientific modeling

  • Distributed analytics

  • CPU-based machine learning inference

Bare metal instances, such as c6g.metal, provide your applications with direct access to physical resources of the host server, such as processors and memory.

C6i and C6id instances

These instances are ideal for running advanced, compute-intensive workloads, such as the following:

  • High-performance computing (HPC)

  • Batch processing

  • Ad serving

  • Video encoding

  • Distributed analytics

  • Highly scalable multiplayer gaming

C6in instances

These instances are well suited for compute-intensive workloads such as the following:

  • Distributed computing applications

  • Network virtual appliances

  • Data analytics

  • High Performance Computing (HPC)

  • CPU-based AI/ML

For more information, see Amazon EC2 C6i Instances.

C7a instances

These instances are powered by 4th generation AMD EPYC processors and are ideal for running advanced, compute-intensive workloads, such as the following:

  • High-performance computing (HPC)

  • Batch processing

  • Ad serving

  • Video encoding

  • Gaming servers

  • Scientific modeling

  • Distributed analytics

For more information, see Amazon EC2 C7a instances.

C7g and C7gd instances

These instances are powered by Amazon Graviton3 processors and are ideal for running advanced, compute-intensive workloads, such as the following:

  • High-performance computing (HPC)

  • Batch processing

  • Ad serving

  • Video encoding

  • Gaming servers

  • Scientific modeling

  • Distributed analytics

For more information, see Amazon EC2 C7g instances.

C7gn instances

Featuring the new Amazon Nitro Cards, C7gn instances deliver the highest network bandwidth, and the best packet-processing performance for Graviton-based Amazon EC2 instances. C7gn instances offer up to 200 Gbps network bandwidth and up to 50 percent higher packet-processing performance compared to previous generation C6gn instances. C7gn instances are ideal for network-intensive workloads, including:

  • Network virtual appliance workloads

  • Data-intensive workloads, such as data analytics

  • CPU-based artificial intelligence and machine learning (AI/ML) inference workloads

For more information, see Amazon EC2 C7g instances.

C7i instances

C7i instances are ideal for running compute intensive workloads, such as batch processing, machine learning, high end gaming, ad serving, and video encoding.

For more information, see Amazon EC2 C7i instances.

Hardware specifications

A virtual central processing unit (vCPU) represents a portion of the physical CPU assigned to a virtual machine (VM). For x86 instances, there are two vCPUs per core. For Graviton instances, there is one vCPU per core.

For hardware specifications, see Compute optimized instances in the Amazon EC2 Instance Types Guide.

Instance performance

EBS-optimized instances enable you to get consistently high performance for your EBS volumes by eliminating contention between Amazon EBS I/O and other network traffic from your instance. Some compute optimized instances are EBS-optimized by default at no additional cost. For more information, see Amazon EBS–optimized instances.

Some compute optimized instance types provide the ability to control processor C-states and P-states on Linux. C-states control the sleep levels that a core can enter when it is inactive, while P-states control the desired performance (in CPU frequency) from a core. For more information, see Processor state control for your EC2 instance.

Network performance

You can enable enhanced networking on supported instance types to provide lower latencies, lower network jitter, and higher packet-per-second (PPS) performance. Most applications do not consistently need a high level of network performance, but can benefit from access to increased bandwidth when they send or receive data. For more information, see Enhanced networking on Linux.

For network specifications, see Compute optimized instances in the Amazon EC2 Instance Types Guide.

Amazon EBS I/O performance

Amazon EBS optimized instances use an optimized configuration stack and provide additional, dedicated capacity for Amazon EBS I/O. This optimization provides the best performance for your Amazon EBS volumes by minimizing contention between Amazon EBS I/O and other traffic from your instance.

For more information, see Amazon EBS–optimized instances.

SSD-based instance store volume I/O performance

Instance store volumes persist only for the life of the instance. When you stop, hibernate, or terminate an instance, the applications and data in its instance store volumes are erased. We recommend that you regularly back up or replicate important data in your instance store volumes. For more information, see Amazon EC2 instance store and SSD instance store volumes.

For instance store volume specifications, see Compute optimized instances in the Amazon EC2 Instance Types Guide.

As you fill the SSD-based instance store volumes for your instance, the number of write IOPS that you can achieve decreases. This is due to the extra work the SSD controller must do to find available space, rewrite existing data, and erase unused space so that it can be rewritten. This process of garbage collection results in internal write amplification to the SSD, expressed as the ratio of SSD write operations to user write operations. This decrease in performance is even larger if the write operations are not in multiples of 4,096 bytes or not aligned to a 4,096-byte boundary. If you write a smaller amount of bytes or bytes that are not aligned, the SSD controller must read the surrounding data and store the result in a new location. This pattern results in significantly increased write amplification, increased latency, and dramatically reduced I/O performance.

SSD controllers can use several strategies to reduce the impact of write amplification. One such strategy is to reserve space in the SSD instance storage so that the controller can more efficiently manage the space available for write operations. This is called over-provisioning. The SSD-based instance store volumes provided to an instance do not have any space reserved for over-provisioning. To reduce write amplification, we recommend that you leave 10 percent of the volume unpartitioned so that the SSD controller can use it for over-provisioning. This decreases the storage that you can use, but increases performance even if the disk is close to full capacity.

For instance store volumes that support TRIM, you can use the TRIM command to notify the SSD controller whenever you no longer need data that you have written. This provides the controller with more free space, which can reduce write amplification and increase performance. For more information, see Instance store volume TRIM support.

Release notes

  • C4 instances and instances built on the Nitro System require 64-bit EBS-backed HVM AMIs. They have high-memory and require a 64-bit operating system to take advantage of that capacity. HVM AMIs provide superior performance in comparison to paravirtual (PV) AMIs on high-memory instance types. In addition, you must use an HVM AMI to take advantage of enhanced networking.

  • C7g instances are powered by the latest generation Amazon Graviton3 processors. They offer up to 25% better performance over the sixth generation Amazon Graviton2-based C6g instances. C7g instances are the first in the cloud to feature DDR5 memory, which provides 50% higher memory bandwidth compared to DDR4 memory to enable high-speed access to data in memory.

    • C7g instances limit the aggregate execution rate of high power instructions such as floating point multiply accumulates across cores in an instance. Future instance types focused on other workload segments may not have this restriction

  • Instances built on the Nitro System have the following requirements:

    The following Linux AMIs meet these requirements:

    • AL2023

    • Amazon Linux 2

    • Amazon Linux AMI 2018.03 and later

    • Ubuntu 14.04 or later with linux-aws kernel

      Note

      Amazon Graviton-based instance types require Ubuntu 18.04 or later with linux-aws kernel

    • Red Hat Enterprise Linux 7.4 or later

    • SUSE Linux Enterprise Server 12 SP2 or later

    • CentOS 7.4.1708 or later

    • FreeBSD 11.1 or later

    • Debian GNU/Linux 9 or later

  • Instances with an Amazon Graviton processors have the following requirements:

    • Use an AMI for the 64-bit Arm architecture.

    • Support booting through UEFI with ACPI tables and support ACPI hot-plug of PCI devices.

    The following AMIs meet these requirements:

    • Amazon Linux 2 (64-bit Arm)

    • Ubuntu 16.04 or later (64-bit Arm)

    • Red Hat Enterprise Linux 8.0 or later (64-bit Arm)

    • SUSE Linux Enterprise Server 15 or later (64-bit Arm)

    • Debian 10 or later (64-bit Arm)

  • To get the best performance from your C6i instances, ensure that they have ENA driver version 2.2.9 or later. Using an ENA driver earlier than version 1.2 with these instances causes network interface attachment failures. The following AMIs have a compatible ENA driver.

    • AL2023

    • Amazon Linux 2 with kernel 4.14.186 and later

    • Ubuntu 20.04 with kernel 5.4.0-1025-aws and later

    • Red Hat Enterprise Linux 8.3 with kernel 4.18.0-240.1.1.el8_3.ARCH and later

    • SUSE Linux Enterprise Server 15 SP2 with kernel 5.3.18-24.15.1 and later

  • The maximum number of Amazon EBS volumes that you can attach to an instance depends on the instance type and instance size. For more information, see Instance volume limits.

  • To get the best performance from your C6gn instances, ensure that they have ENA driver version 2.2.9 or later. Using an ENA driver earlier than version 1.2 with these instances causes network interface attachment failures. The following AMIs have a compatible ENA driver.

    • AL2023

    • Amazon Linux 2 with kernel 4.14.186 and later

    • Ubuntu 20.04 with kernel 5.4.0-1025-aws and later

    • Red Hat Enterprise Linux 8.3 with kernel 4.18.0-240.1.1.el8_3.ARCH and later

    • SUSE Linux Enterprise Server 15 SP2 with kernel 5.3.18-24.15.1 and later

  • To launch AMIs for all Linux distributions on C6gn instances, use AMIs with the latest version and run an update for the latest driver. For earlier versions, download the latest driver from GitHub.

  • Launching a bare metal instance boots the underlying server, which includes verifying all hardware and firmware components. This means that it can take 20 minutes from the time the instance enters the running state until it becomes available over the network.

  • To attach or detach EBS volumes or secondary network interfaces from a bare metal instance requires PCIe native hotplug support. Amazon Linux 2 and the latest versions of the Amazon Linux AMI support PCIe native hotplug, but earlier versions do not. You must enable the following Linux kernel configuration options:

    CONFIG_HOTPLUG_PCI_PCIE=y CONFIG_PCIEASPM=y
  • Bare metal instances use a PCI-based serial device rather than an I/O port-based serial device. The upstream Linux kernel and the latest Amazon Linux AMIs support this device. Bare metal instances also provide an ACPI SPCR table to enable the system to automatically use the PCI-based serial device. The latest Windows AMIs automatically use the PCI-based serial device.

  • Instances built on the Nitro System should have acpid installed to support clean shutdown through API requests.

  • There is a limit on the total number of instances that you can launch in a Region, and there are additional limits on some instance types. For more information, see How many instances can I run in Amazon EC2? in the Amazon EC2 FAQ.