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

Pod MTU #2791

Merged
merged 1 commit into from Feb 14, 2024
Merged

Pod MTU #2791

merged 1 commit into from Feb 14, 2024

Conversation

jchen6585
Copy link
Contributor

What type of PR is this?

feature

Which issue does this PR fix:
#2606

What does this PR do / Why do we need it:
Implements a new env var POD_MTU that sets the pod MTU. This will default to AWS_VPC_ENI_MTU value if not set.

If an issue # is not available please add repro steps and logs from IPAMD/CNI showing the issue:

Testing done on this change:

Ran CNI, IPAMD, and IPv6 test suites.

Will this PR introduce any new dependencies?:

No

Will this break upgrades or downgrades? Has updating a running cluster been tested?:
No, Yes

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

No

Does this PR introduce any user-facing change?:

Yes

By setting `POD_MTU`, you can have different MTU values for the pod and ENI.

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

@jchen6585 jchen6585 requested a review from a team as a code owner February 8, 2024 22:05
@@ -267,6 +267,14 @@ Default: empty
Specify a comma-separated list of IPv4 CIDRs to exclude from SNAT. For every item in the list an `iptables` rule and off\-VPC
IP rule will be applied. If an item is not a valid ipv4 range it will be skipped. This should be used when `AWS_VPC_K8S_CNI_EXTERNALSNAT=false`.

#### `POD_MTU` (v1.x.x+)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Placeholder version

README.md Show resolved Hide resolved
cmd/aws-vpc-cni/main.go Outdated Show resolved Hide resolved
test/integration/cni/host_networking_test.go Outdated Show resolved Hide resolved
test/integration/ipv6/ipv6_host_networking_test.go Outdated Show resolved Hide resolved
@jdn5126 jdn5126 merged commit 0129baf into aws:master Feb 14, 2024
6 checks passed
*Note*: The default value is set to AWS_VPC_ENI_MTU, which defaults to 9001 if unset.
Default: 9001

Used to configure the MTU size for pod virtual interfaces. The valid range is from `576` to `9001`.
Copy link

Choose a reason for hiding this comment

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

576 is only valid for IPv4, otherwise the minimum MTU has to be 1280 (IPv6)

Copy link
Contributor

Choose a reason for hiding this comment

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

Good call @archoversight. @jchen6585 we should update the README for AWS_VPC_ENI_MTU and POD_MTU at the very least, and we can consider adding runtime logging to error if IPv6 is configured and the MTU is < 1280

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.

None yet

3 participants