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

Feat/support ip6tnlmtu fix the issue that cause lo refcount leak #1

Merged
merged 8 commits into from
Apr 4, 2025

Conversation

xujihui1985
Copy link

We recently encountered a kernel bug similar to the one described in this thread. The root cause of the issue is that Dst objects get leaked in ip6_negative_advice() when this function is executed for an expired IPv6 route located in the exception table but the trigger of this issue was the router responds with an ICMP “Message Too Long” message, which triggers an MTU change. This, in turn, causes a route entry to be added to the route cache, eventually leading to the kernel bug mentioned above.

This problem occurs when communicating across hosts because the MTU of the ip6tnl interface is 1450, which is smaller than the MTU of the NIC. As a result, the MTU mismatch causes the IP is cached and trigger the subtle bug

image

The purpose of this PR is to introduce a new configuration option that allows setting a custom MTU for the ip6tnl interface to prevent this issue.

@xujihui1985
Copy link
Author

@moycat Hi, that will be appreciated if you have time to review this PR

Copy link
Owner

@moycat moycat left a comment

Choose a reason for hiding this comment

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

Thanks! Please check these minor suggestions.

@xujihui1985
Copy link
Author

Thanks! Please check these minor suggestions.

I’ve made the requested changes and updated the PR accordingly. Please let me know if you need any further adjustments.

@moycat
Copy link
Owner

moycat commented Apr 4, 2025

LGTM. Thanks a lot!

@moycat moycat merged commit ae11f41 into moycat:master Apr 4, 2025
4 checks passed
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