EC2 network performance demystified: m3 and m4

AWS offers EC2 instances in different sizes, defined by the instance type. How do you decide which instance type to use? Do you need an m4.large or m4.xlarge instance? At least the following factors should affect your decision:

  • How much memory does the operating system and application need?
  • Does your application benefit from multiple CPU cores?
  • What is the expected network throughput going in and out your instance?

It’s easy to get the information about the memory and CPU capacity of an instance type at Amazon EC2 Instance Types. For example, an m4.large instance comes with two vCPUs and 8 GiB memory. But which network performance can you expect with an m4.large instance? AWS promises a Moderate network performance without any hint how to translate this vague information into GBit/s.

I’ve been dissatisfied with the lack of information about the actual network performance of EC2 instances for a while. Therefore, I remembered the saying my father told me: “Messen heißt wissen!” which translates to “Measuring means knowledge!”.

Over the last weeks, I’ve measured the networking performance of EC2 instances in the real world, and I’m happy to share the results with you.

Summary of the benchmarking infrastructure:

  • benchmarking tool: iperf3
  • instance type of iperf3 server: m4.16xlarge
  • regions: eu-west-1 and us-west-2
  • period: every 3 hours from November 22th, 2017 to November 28, 2017

Expect a detailed blog post explaining my benchmark infrastructure in the future.

m3 Instance Family

The benchmark results within the m3 instance family are very consistent with a minimal variance between different measurements. Expect a network throughput from 0.3 Gbps to 1.0 Gbps with m3 instances.

INSTANCE TYPE TARGET MIN MAX AVG STDDEV
m3.medium Moderate 0.32 0.32 0.32 0.00
m3.large Moderate 0.70 1.22 0.70 0.04
m3.xlarge High 1.01 1.01 1.01 0.00
m3.2xlarge High 1.01 1.01 1.01 0.00

The following chart shows the average networking performance of the different m3 instance types.

Network Performance of m3 Instance Family

m4 Instance Family

The variance is much higher between measurements of the same instance type within the m4 family. AWS specifies the network throughput for the m4.10xlarge and m4.16xlarge instance types in detail: 10 Gbps and 25 Gbps.

INSTANCE TYPE TARGET MIN MAX AVG STDDEV
m4.large Moderate 0.47 4.08 0.49 0.25
m4.xlarge High 0.79 2.85 0.81 0.18
m4.2xlarge High 1.01 1.06 1.01 0.00
m4.4xlarge High 2.03 2.73 2.05 0.12
m4.10xlarge 10 Gbps 5.00 9.86 7.22 2.42
m4.16xlarge 25 Gbps 12.42 24.63 23.93 1.20

The following chart illustrates the networking performance of the m4 instance family. The vertical line shows min/max throughput in seconds. The box indicates the average +/- standard deviation.

Network Performance of m4 Instance Family

Summary

When choosing an instance type, the network performance should be one of the main criteria. Especially, for network-intensive workloads. As AWS is only providing very vague information about the networking performance of each instance types our benchmark helps you to avoid bottlenecks caused by the networking capacity of your instances.

Networking benchmarks of other instance families will follow!

Published on


Subscribe to free monthly updates.

One subscriber wins our book AWS in Action every month.

Andreas Wittig

Andreas Wittig

I’m the author of Amazon Web Services in Action. I work as a software engineer, and independent consultant focused on AWS and DevOps.

Is anything missing in my article? I'm looking forward to your feedback! @andreaswittig or andreas@widdix.de.

marbot

Are you part of a highly motivated DevOps team? Use marbot, a friendly chatbot, to forward all kind of alerts from your AWS infrastructure to Slack. Alerts are escalated across your team automatically allowing you to focus on your daily work.

Amazon Web Services in Action

Amazon Web Services in Action introduces you to computing, storing, and networking in the AWS cloud.

Customer Reviews:

Subscribe to free monthly updates.

One subscriber wins our book AWS in Action every month.


Subscribe for free