By using AWS re:Post, you agree to the AWS re:Post Terms of Use

How to increase max pods number in Amazon Linux 2023 instances?

0

I have an EKS cluster and I am using managed node groups with custom launch template. I was using EKS optimized AMIs with Amazon Linux 2, and now I want to change those to Amazon Linux 2023. There are few major changes in this AL 2023 vs AL 2, but I think I overcome most of them, I am able to spawn nodes from my node groups and all is good.

But now, the max-pods is set to a fixed amount per instance type. For my previous use case with AL 2, I could put into the user-data a custom command for bootstrap.sh, where I could force to use max-pods = 110, no matter the instance type. But for AL 2023, this is not possible; there is no bootstrap.sh script, and I can't find out how to do this.

I definitely need to set max-pods = 110 for a 2xlarge or even a xlarge instance, current limit is too low (58).

Any suggestions? Thank you.

asked a month ago38 views
1 Answer
1
Accepted Answer

I was able to overcome this by specifying kubelet config setting via the YAML configuration passed directly to nodeadm via user-data, for example:

Content-Type: application/node.eks.aws
MIME-Version: 1.0
---
apiVersion: node.eks.aws/v1alpha1
kind: NodeConfig
spec:
  cluster:
    name: my-cluster
    apiServerEndpoint: https://xxxxx.yy.us-east-1.eks.amazonaws.com
    certificateAuthority: xyz
    cidr: 10.100.0.0/16
  kubelet:
    config:
        maxPods: 110
answered a month ago
profile picture
EXPERT
reviewed 20 days ago
profile picture
EXPERT
reviewed a month ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions