Closed LoneWolff7 closed 3 months ago
The truth is that I have never had to deal with this problem. Let's leave this issue open to see if anyone else has this problem and can give us more information.
My understanding is that the Cellular Link will have an MTU, the wifi link will have it's own MTU. The zerotier interface will default to 2800. I would have thought that the network stack on openwrt would fragment the packets from zerotier when routing out of which ever interface. And that would just work.
Maybe there is something about this configuration we are missing? Can you describe the setup a bit further with all the links?
ip link
or
ifconfig
should show the MTU settings of all the interfaces.
You could also check this from some other device on the wifi network to confirm the best MTU for that network.
I also see there are long running discussions on zerotier MTU values at here where the goal is to identify the highest MTU that will work across links. I believe that is what is needed.
My understanding is that the Cellular Link will have an MTU, the wifi link will have it's own MTU. The zerotier interface will default to 2800. I would have thought that the network stack on openwrt would fragment the packets from zerotier when routing out of which ever interface. And that would just work.
I’m not using Zerotier anymore, but I was talking about 5G cellular on my phone, in this case. With mtu at default 2800 Zerotier would work while connected to wifi but as I switch to my carrier’s 5G SA network it would stop working.
Adjusting the mtu using ifconfig <zerotier id> mtu 1280
used to work but it would stop working randomly, and I had to fiddle with mtu size to get to work again.
I’m using Tailscale currently and it uses a default mtu size of 1280 and has no issues working between WiFi and mobile networks.
According to the documentation the MTU value of a ZT network can be adjusted through the API.
TOKEN="your_my.zerotier.one_api_token"
NETWORK_ID="your_network_id"
curl -X POST \
-H "Authorization: token ${TOKEN}" \
-d '{"config": {"mtu": 1280}}' \
"https://my.zerotier.com/api/v1/network/${NETWORK_ID}"
Once this request is made, by simply stopping and restarting the ZT daemon on the nodes, the new configuration is picked up automatically and the whole system starts working with the new MTU.
This is still an issue; clients using ZeroTier version 1.14.0.
Hi @pjkundert
From the previous posts on this issue, you would need to determine what the max MTU is on mobile phone to your provider. Then do the same for your wifi connection.
From the zerotier discission on this topic, it seems likely you phone service provider is blocking path mtu. If that is the case, then setting the zerotier config to the lower of the two MTU values should ensure connectivity.
With the default mtu of 2800 zerotier doesn’t work on 5G cellular data. I have to manually change the mtu to 1280 to get it to work on cellular, but then it struggles on wifi.
Is there a permanent way to fix this issue?