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

allow to change MTU for all VPNs #2044

Open
ak370 opened this issue Jan 13, 2024 · 3 comments · May be fixed by #2221
Open

allow to change MTU for all VPNs #2044

ak370 opened this issue Jan 13, 2024 · 3 comments · May be fixed by #2221

Comments

@ak370
Copy link

ak370 commented Jan 13, 2024

What's the feature 🧐

In certain circumstances MTU needs to be smaller as some networks have issues. Wireguard side seems to have now(link below) MTU parameter but not OpenVPN. Can there be a feature that allows setting lower MTU irrespective of if it is Wireguard or OpenVPN.
I resolve OpenVPN MTU limit problem simply executing below after starting the container, however this should be configurable parameter.
docker exec f86573009ed6 /sbin/ip link set dev tun0 up mtu 1300

#1650

Extra information and references

No response

@qdm12
Copy link
Owner

qdm12 commented Apr 29, 2024

Does using OPENVPN_MSSFIX=1272 fixes it (1300-28)?

@ak370
Copy link
Author

ak370 commented Apr 29, 2024

Does using OPENVPN_MSSFIX=1300 fixes it?

This flag doesn't to change the MTU is still 1500, however unable to verify as it works at the moment without any flags anyway.

2: tun0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN mode DEFAULT group default qlen 500
link/none

@qdm12
Copy link
Owner

qdm12 commented May 2, 2024

See the mssfix documentation at https://openvpn.net/community-resources/reference-manual-for-openvpn-2-6/

Basically the mtu is unchanged, but internal TCP connections will have packets at most as MTU-MSSFIX. I guess your issues are related to TCP (tunneled over UDP), if you have issues with UDP tunneled over UDP, then using the --fragment option might be of interest but that's rather rare so far and I would prefer to no add this option.

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

Successfully merging a pull request may close this issue.

2 participants