vxlan code is missing max_frame_size callback which is now mandatory if you want to be able to do the change. If vxlan code doesn’t care about that change, it can be as simple as:
vxlan_set_max_frame_size (vnet_main_t *vnm, vnet_hw_interface_t *hw, u32 frame_size) { return 0; } and: eir.cb.set_max_frame_size = vxlan_set_max_frame_size; right before call to vnet_eth_register_interface (vnm, &eir); However right solution will be to allow/disallow change based on underlying MTU….. — Damjan > On 17.02.2022., at 12:11, Pim van Pelt <p...@ipng.nl> wrote: > > Hoi Artyom, > > Not an authoritative answer, although perhaps Damjan can confirm: > Is the semantic difference between max frame size (==device will reject > frames larger than that on Rx, and never Tx frames larger than that) and mtu > (L3 IP/IP6/MPLS packets will not be larger than that) with an implication > that MTU can bever be larger than max_frame_size. > > Regardless, Artyom, here's how I manipulate the MTU of VXLAN tunnels - the > trick is to use the 'mtu packet' rather than 'mtu' option (see the CLI call > in bold): > > create vxlan tunnel instance 10 src $A dst $B vni 320501 decap-next l2 > set interface state vxlan_tunnel10 up > set interface mtu packet 1522 vxlan_tunnel10 > set interface l2 xconnect TenGigabitEthernet5/0/0.50 vxlan_tunnel10 > set interface l2 xconnect vxlan_tunnel10 TenGigabitEthernet5/0/0.50 > > pim@ddln1:~$ vppctl show ver > vpp v22.06-rc0~93-g360aee3e0 built by pim on dellr610 at 2022-02-13T11:56:07 > > pim@ddln1:~$ vppctl show int vxlan_tunnel10 > Name Idx State MTU (L3/IP4/IP6/MPLS) > Counter Count > vxlan_tunnel10 17 up 1522/0/0/0 rx > packets 209408 > rx bytes > 81834552 > tx > packets 1616124 > tx bytes > 2471872228 > > Does that help for you? I actually noticed that it doesn't prevent > vxlan_tunnel10 from emitting larger frames, so I'm not quite sure what > benefit it brings. > > On Thu, Feb 17, 2022 at 11:38 AM Artyom Glazychev > <artyom.glazyc...@xored.com> wrote: > Hello, > > There is a problem with setting MTU for VxLAN. I see, that there was a change > related to MTU and Max_frame_size - https://gerrit.fd.io/r/c/vpp/+/34928 > > I don't know, what VxLAN configuration is right (I've asked about it here > https://lists.fd.io/g/vpp-dev/topic/vxlan_l3_mode/89205942?p=,,,20,0,0,0::recentpostdate/sticky,,,20,2,0,89205942,previd=1645090589967474984,nextid=1643993575016104745&previd=1645090589967474984&nextid=1643993575016104745) > > But neither this: > DBGvpp# create vxlan tunnel src 10.0.3.1 dst 10.0.3.3 vni 55 l3 > vxlan_tunnel0 > DBGvpp# set interface mtu 1400 vxlan_tunnel0 > set interface mtu: Unsupported (underlying driver doesn't support changing > Max Frame Size) > > Nor this: > DBGvpp# create vxlan tunnel src 10.0.3.1 dst 10.0.3.3 vni 55 > vxlan_tunnel0 > DBGvpp# set interface mtu 1400 vxlan_tunnel0 > set interface mtu: not supported > is not working. > > So, my final question is how to configure the VxLAN L2-tunnel and set MTU? > Thank you. > > > > > > > -- > Pim van Pelt <p...@ipng.nl> > PBVP1-RIPE - http://www.ipng.nl/ > > >
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#20877): https://lists.fd.io/g/vpp-dev/message/20877 Mute This Topic: https://lists.fd.io/mt/89206535/21656 Group Owner: vpp-dev+ow...@lists.fd.io Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-