Score:0

MTU resetting back to 1500 after `netplan apply`

in flag

I'm trying to change the MTU of the eth0 interface on my machine running Ubuntu 18.04 (Nvidia Jetson Xavier NX). Running sudo netplan apply successfully sets the mtu for eth0 to 1280.

Unfortunately, within a minute, my SSH connection is dropped. I notice MTU is reset to 1500 when I eventually reconnect. I can see that with ifconfig eth0. This is not a problem for Ubuntu 20.04 (on NVIDIA AGX Orin).

I've added the following to my netplan YAML config directory (/etc/netplan/eth0.yaml):

network:
  version: 2
  renderer: NetworkManager
  ethernets:
    eth0:
      dhcp4: true
        use-mtu: false
      mtu: 1280

Model: NVIDIA Jetson Xavier NX Developer Kit - Jetpack 4.6 [L4T 32.6.1]

Question:

Why does the MTU reset to 1500 within a few minutes? I don't think I should follow https://unix.stackexchange.com/questions/314994/mtu-keeps-getting-reset-to-1500, since this could cause an continuous network disconnections every few minutes.


Extra detail: why I want the MTU to be 1280.

I'm using Tailscale for accessing my devices, and these devices can also use tailscale to access other services. Tailscale doesn't support 1500 MTU, I've tried it on other devices and it doesn't work. Their default is 1280. Their release notes state:

TS_DEBUG_MTU environment variable can be set to change the tailscale0 MTU size; has to be changed for both nodes wanting to use larger packets. Setting the MTU larger than 1468 is unlikely to work. For Linux platforms, it can be set in /etc/default/tailscaled source

My device runs microk8s with Flanneld, and the containers inside don't know which interface they'll use. Flanneld will use the host network interface to determine the MTU to use. I think they should resort to creating packets with max size of 1280 bytes, in case these bytes are destined to go via tailscale. Therefore, I need to set eth0's mtu to 1280.

I also wrote my question on the NVIDIA forums.

A.B avatar
cl flag
A.B
As commented in similar resetting setups. To know when this happened (but not what did it): keep a `ip -ts monitor link dev eth0` running and compare time with other logs of other tools. Hopefully you'll be able to correlate with some logs.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.