Kubernetes Max PODS per Node calculator - AWS EKS | Devops Junction

Managed Kubernetes such as AWS EKS come with their own limitations.

One such limitation is how many PODs a Worker node can have based on the type of EC2 instance

For example,

  • t3.medium can have only 17 pods
  • t3.large can have 35 pods

These limitations are there for operational reasons.

To be more precise let us take the t3.medium instance, It can have only 3 network interfaces and 6 IPv4 addresses per each network interface

With a simple formula given below, you can calculate how many pods can t3.medium support.

We also have made a tool which can help you find the max pods for all supported EC2 instances

 

How to calculate the Maximum Number of pods supported by the Ec2 instance

here is the formula that can help.

  • The first IP on each ENI is not used for pods
  • +2 for the pods that use host networking (AWS CNI and kube-proxy)
 # of ENI * (# of IPv4 per ENI - 1) + 2

It's not always easy to go and do the math before scheduling every time.

 

Pods per EC2 instance - Max Pods Calculator

I have created this tool that does the math for you and it updates automatically every week.

This is created using EC2 API and a GOlang project named MaxPodEKS which I will release it open source soon

Hope it helps.

Cheers
Sarav AK