Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add trn1 limits #2092

Merged
merged 3 commits into from
Sep 22, 2022
Merged

Add trn1 limits #2092

merged 3 commits into from
Sep 22, 2022

Conversation

cartermckinnon
Copy link
Member

What type of PR is this?

Feature

Which issue does this PR fix:

N/A

What does this PR do / Why do we need it:

This adds trn1 instance types to the files generated by make generate-limits. I also modified the script to properly handle instance types with multiple network cards, which allowed me to remove some of the manual overrides. I also removed other manual overrides that were no longer necessary.

Testing done on this change:

> make generate-limits
go run  scripts/gen_vpc_ip_limits.go
2022-09-21 12:55:29.797646 -0700 PDT m=+0.004118698 write error: can't make directories for new logfile: mkdir /host: read-only file system
2022-09-21 12:55:29.797746 -0700 PDT m=+0.004219257 write error: can't make directories for new logfile: mkdir /host: read-only file system
{"level":"info","ts":"2022-09-21T12:55:31.056-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=ap-northeast-1"}
{"level":"info","ts":"2022-09-21T12:55:34.191-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=ap-northeast-2"}
{"level":"info","ts":"2022-09-21T12:55:36.796-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=ap-northeast-3"}
{"level":"info","ts":"2022-09-21T12:55:38.847-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=ap-south-1"}
{"level":"info","ts":"2022-09-21T12:55:42.991-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=ap-southeast-1"}
{"level":"info","ts":"2022-09-21T12:55:46.846-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=ap-southeast-2"}
{"level":"info","ts":"2022-09-21T12:55:50.381-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=ca-central-1"}
{"level":"info","ts":"2022-09-21T12:55:52.886-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=eu-central-1"}
{"level":"info","ts":"2022-09-21T12:55:56.787-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=eu-north-1"}
{"level":"info","ts":"2022-09-21T12:55:59.862-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=eu-west-1"}
{"level":"info","ts":"2022-09-21T12:56:03.780-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=eu-west-2"}
{"level":"info","ts":"2022-09-21T12:56:06.886-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=eu-west-3"}
{"level":"info","ts":"2022-09-21T12:56:09.935-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=sa-east-1"}
{"level":"info","ts":"2022-09-21T12:56:13.472-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=us-east-1"}
{"level":"info","ts":"2022-09-21T12:56:16.646-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=us-east-2"}
{"level":"info","ts":"2022-09-21T12:56:19.458-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=us-west-1"}
{"level":"info","ts":"2022-09-21T12:56:21.425-0700","caller":"/Users/mckdev/github/amazon-vpc-cni-k8s/scripts/gen_vpc_ip_limits.go:58","msg":"Describing instance types in region=us-west-2"}
Adding "cr1.8xlarge": {8 30 unknown false} since it is missing from the API
Adding "u-24tb1.metal": {15 50 unknown true} since it is missing from the API
Adding "u-6tb1.metal": {5 30 unknown true} since it is missing from the API
Adding "c5ad.metal": {15 50 unknown true} since it is missing from the API
Adding "p4de.24xlarge": {15 50 unknown false} since it is missing from the API
Adding "hs1.8xlarge": {8 30 unknown false} since it is missing from the API
Adding "u-12tb1.metal": {5 30 unknown true} since it is missing from the API
Adding "u-18tb1.metal": {15 50 unknown true} since it is missing from the API
Adding "u-9tb1.metal": {5 30 unknown true} since it is missing from the API
Adding "c5a.metal": {15 50 unknown true} since it is missing from the API
Adding "c7g.metal": {15 50 unknown true} since it is missing from the API
{"level":"info","ts":"2022-09-21T12:56:22.399-0700","caller":"/usr/local/go/src/runtime/proc.go:250","msg":"Generated pkg/awsutils/vpc_ip_resource_limit.go"}
{"level":"info","ts":"2022-09-21T12:56:22.405-0700","caller":"/usr/local/go/src/runtime/proc.go:250","msg":"Generated misc/eni-max-pods.txt"}

Automation added to e2e:

N/A

Will this PR introduce any new dependencies?:

No.

Will this break upgrades or downgrades. Has updating a running cluster been tested?:

No.

Does this change require updates to the CNI daemonset config files to work?:

No.

Does this PR introduce any user-facing change?:

Yes.

`trn1` instance types are now supported.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@cartermckinnon cartermckinnon requested a review from a team as a code owner September 21, 2022 20:11
"c7g.8xlarge": {ENILimit: 8, IPv4Limit: 30, HypervisorType: "nitro", IsBareMetal: false},
"c7g.large": {ENILimit: 3, IPv4Limit: 10, HypervisorType: "nitro", IsBareMetal: false},
"c7g.medium": {ENILimit: 2, IPv4Limit: 4, HypervisorType: "nitro", IsBareMetal: false},
"c7g.xlarge": {ENILimit: 4, IPv4Limit: 15, HypervisorType: "nitro", IsBareMetal: false},
Copy link
Member Author

@cartermckinnon cartermckinnon Sep 21, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed these based on the scripts output (with the above modifications):

Delete "c6g.xlarge": {4 15 nitro false} is already correct in the API
Delete "c7g.12xlarge": {8 30 nitro false} is already correct in the API
Delete "c7g.16xlarge": {15 50 nitro false} is already correct in the API
Delete "c7g.2xlarge": {4 15 nitro false} is already correct in the API
Delete "c7g.4xlarge": {8 30 nitro false} is already correct in the API
Delete "c7g.8xlarge": {8 30 nitro false} is already correct in the API
Delete "c7g.large": {3 10 nitro false} is already correct in the API
Delete "c7g.medium": {2 4 nitro false} is already correct in the API
Delete "c7g.xlarge": {4 15 nitro false} is already correct in the API
Replacing API value {15 50 nitro false} with override {15 50 unknown false} for "dl1.24xlarge"
Replacing API value {15 50 nitro false} with override {15 50 unknown false} for "p4d.24xlarge"

@cartermckinnon
Copy link
Member Author

@jayanthvn I can't reproduce the make check-format failures locally, and the go mod download failure seems unrelated to this change. Any ideas?

@jayanthvn
Copy link
Contributor

@jayanthvn I can't reproduce the make check-format failures locally, and the go mod download failure seems unrelated to this change. Any ideas?

Can you just try running "make format" ?

@cartermckinnon
Copy link
Member Author

Yes, git diff is empty when I do that, can you reproduce this?

@jayanthvn
Copy link
Contributor

Yeah, I did try to repo and I don't see any diff either -

git status
On branch trn-limits
Your branch is up to date with 'origin/trn-limits'.

nothing to commit, working tree clean

Will review and merge it. I will test on master post merge.

Copy link
Contributor

@jayanthvn jayanthvn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@jayanthvn jayanthvn merged commit 3ca86c7 into aws:master Sep 22, 2022
@jayanthvn
Copy link
Contributor

Even the master looks clean after the merge -

git status
On branch master
Your branch is up to date with 'origin/master'.

nothing to commit, working tree clean

@cartermckinnon cartermckinnon deleted the trn-limits branch September 22, 2022 18:34
@cartermckinnon
Copy link
Member Author

Weird. But thanks for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants