[LEDE-DEV] "Native" way to set a wireless link's MTU?

Jeff Kletsky lede at allycomm.com
Thu Apr 5 14:26:02 PDT 2018


I've been struggling with an OpenWRT configuration to get a specific
wireless link to come with with an MTU of higher than 1500. I have
administrative control over all endpoints so interop is not a concern.

At least as I understand it, 802.11 itself has a 2304 MTU and I'd like
to explicitly take advantage of a few dozen bytes of that on a
dedicated link that is tunneling encapsulated 1500-MTU packets at
Layer 2. PMTU discovery over the restricted link fails, likely because
the packets are not _routed_ and are dropped silently by the Linux
bridge.

clients   "External" clients, unaware that there is a sub-1500 PMTU
           or that PMTU discovery will fail
  | | |

  br-XXX   MTU 1500 ok; adopts MTU as minimum of bridged interfaces

    |

gre4t-gt  Can set to MTU 1500 with UCI
           adds 24 bytes GRE over IPv4 + 22(?) bytes of L2 encap
    |

br-mesh   Need "1548+" MTU; adopts MTU as that of bridged interface, mesh0
           Assigned the tunnel endpoint IP address
    |      "Required" for UCI config as apparently can't directly modify 
mesh0

  mesh0   Auto-generated wireless interface; comes up with 1500 MTU

    Ψ

(the reverse on the other side of the link)


The "obvious" approach of explicitly naming the wireless interface
("mesh0") in /etc/config/wireless and setting the mtu in
/etc/config/network doesn't seem to work.

config interface 'mesh0'
         option mtu 2304

(either with or without "option proto none")

I can change the MTU of the wireless link "manually" with ip with some
kind of an "interface-up" script, but would prefer to handle this
"natively" with netifd, wpa_supplicant, or the like.

"In a perfect world" I would also be able to set the IP address directly
on the wireless device, getting rid of br-mesh entirely, but I haven't
found a way to accomplish that through UCI configuration.

I'm not adverse to patching code and compiling a custom image.

TIA,

Jeff





More information about the Lede-dev mailing list