Wireguard and MTU -- FYI

I’m not sure that this is Sailfish-specific, but it struck me on Sailfish, so the information might be useful to others.

If you use WireGuard, and it is very slow, or connections time out left and right, reduce the MTU on the connection to around 1200 (from 1500). You can do it globally on the server end.

I have an OpenWRT router at home as WG server, and it works with Android (eos on an FP4) and WGtunnel, and with Linux/Gnome/NetworkManager.

An essentially identical configuration was unusable on SF5.2, as everything was either horribly slow or timed out constantly.

By lowering the MTU on the server side (there is no way to set it on the phone UI), it is smooth sailing all the time.

I’m very new to the Jolla Phone and SailFish, so I don’t know why it struck there and not elsewhere.

Tethering a Linux laptop (debian trixie) to the Jolla phone through Wi-Fi, and using the identical configuration on the laptop, showed the same problems. Lowering the MTU on the laptop solved it.

It might be something in the SF TCP/IP stack, but the two have almost the same Linux version (6.12.xxx).

Thank you for the information, but there seem to be more variables to that - I use a Proton-via-Wireguard combo and cannot confirm connectivity/speed issues (JP2026, 5.2.0.17).
Cheers

Proton might set a smaller MTU. The server can set a maximum - that’s how I solved it.

Are you saying you are seeing pMTU problems even if wireguard is not involved?

Do you have some kind of unusual network-related things set, like jumbo frames, something (firewall) dropping ICMP overzealously and such?

No, only when tunnelled. Now, with a lower MTU set on the server end, it works like a charm.