Lines Matching full:mtu
4 # Check that route PMTU values match expectations, and that initial device MTU
12 # created if link layer MTU is not exceeded, then exceed it and check that
14 # below for IPv6 doesn't apply here, because, on IPv4, administrative MTU
20 # created by exceeding link layer MTU with ping to other endpoint. Then
21 # decrease and increase MTU of tunnel, checking that route exception PMTU
26 # endpoints. Check that MTU assigned to vti interface is the MTU of the
34 # Set up vti4 interface passing MTU value at link creation, check MTU is
35 # configured, and that link is not created with invalid MTU values
42 # and check that configured MTU is used on link creation and changes, and
43 # that MTU is properly calculated instead when MTU is not configured from
55 pmtu_vti4_default_mtu vti4: default MTU assignment
56 pmtu_vti6_default_mtu vti6: default MTU assignment
57 pmtu_vti4_link_add_mtu vti4: MTU setting on link creation
58 pmtu_vti6_link_add_mtu vti6: MTU setting on link creation
59 pmtu_vti6_link_change_mtu vti6: MTU changes on link changes"
186 mtu() { function
189 mtu="${3}"
191 ${ns_cmd} ip link set dev ${dev} mtu ${mtu}
200 [ "${i}" = "mtu" ] && next=1
242 mtu "${ns_a}" veth_a ${veth_mtu}
243 mtu "${ns_b}" veth_b ${veth_mtu}
244 mtu "${ns_a}" vti4_a ${vti_mtu}
245 mtu "${ns_b}" vti4_b ${vti_mtu}
247 # Send DF packet without exceeding link layer MTU, check that no
256 # Now exceed link layer MTU by one byte, check that exception is created
275 # Create route exception by exceeding link layer MTU
276 mtu "${ns_a}" veth_a 4000
277 mtu "${ns_b}" veth_b 4000
278 mtu "${ns_a}" vti6_a 5000
279 mtu "${ns_b}" vti6_b 5000
284 err " tunnel exceeding link layer MTU didn't create route exception"
288 # Decrease tunnel MTU, check for PMTU decrease in route exception
289 mtu "${ns_a}" vti6_a 3000
292 err " decreasing tunnel MTU didn't decrease route exception PMTU"
296 # Increase tunnel MTU, check for PMTU increase in route exception
297 mtu "${ns_a}" vti6_a 9000
299 err " increasing tunnel MTU didn't increase route exception PMTU"
309 # Check that MTU of vti device is MTU of veth minus IPv4 header length
313 err " vti MTU ${vti4_mtu} is not veth MTU ${veth_mtu} minus IPv4 header length"
321 # Check that MTU of vti device is MTU of veth minus IPv6 header length
325 err " vti MTU ${vti6_mtu} is not veth MTU ${veth_mtu} minus IPv6 header length"
343 …${ns_a} ip link add vti4_a mtu ${v} type vti local ${veth4_a_addr} remote ${veth4_b_addr} key 10 2…
344 # This can fail, or MTU can be adjusted to a proper value
346 mtu="$(link_get_mtu "${ns_a}" vti4_a)"
347 if [ ${mtu} -lt ${min} -o ${mtu} -gt ${max} ]; then
348 err " vti tunnel created with invalid MTU ${mtu}"
356 ${ns_a} ip link add vti4_a mtu ${v} type vti local ${veth4_a_addr} remote ${veth4_b_addr} key 10
357 mtu="$(link_get_mtu "${ns_a}" vti4_a)"
359 if [ "${mtu}" != "${v}" ]; then
360 err " vti MTU ${mtu} doesn't match configured value ${v}"
381 …${ns_a} ip link add vti6_a mtu ${v} type vti6 local ${veth6_a_addr} remote ${veth6_b_addr} key 10 …
382 # This can fail, or MTU can be adjusted to a proper value
384 mtu="$(link_get_mtu "${ns_a}" vti6_a)"
385 if [ ${mtu} -lt ${min} -o ${mtu} -gt ${max} ]; then
386 err " vti6 tunnel created with invalid MTU ${v}"
394 ${ns_a} ip link add vti6_a mtu ${v} type vti6 local ${veth6_a_addr} remote ${veth6_b_addr} key 10
395 mtu="$(link_get_mtu "${ns_a}" vti6_a)"
397 if [ "${mtu}" != "${v}" ]; then
398 err " vti6 MTU ${mtu} doesn't match configured value ${v}"
409 ${ns_a} ip link add dummy0 mtu 1500 type dummy
411 ${ns_a} ip link add dummy1 mtu 3000 type dummy
420 # Create vti6 interface bound to device, passing MTU, check it
421 ${ns_a} ip link add vti6_a mtu 1300 type vti6 remote ${dummy6_0_addr} local ${dummy6_0_addr}
422 mtu="$(link_get_mtu "${ns_a}" vti6_a)"
423 if [ ${mtu} -ne 1300 ]; then
424 err " vti6 MTU ${mtu} doesn't match configured value 1300"
428 # Move to another device with different MTU, without passing MTU, check
429 # MTU is adjusted
431 mtu="$(link_get_mtu "${ns_a}" vti6_a)"
432 if [ ${mtu} -ne $((3000 - 40)) ]; then
433 err " vti MTU ${mtu} is not dummy MTU 3000 minus IPv6 header length"
437 # Move it back, passing MTU, check MTU is not overridden
438 ${ns_a} ip link set vti6_a mtu 1280 type vti6 remote ${dummy6_0_addr} local ${dummy6_0_addr}
439 mtu="$(link_get_mtu "${ns_a}" vti6_a)"
440 if [ ${mtu} -ne 1280 ]; then
441 err " vti6 MTU ${mtu} doesn't match configured value 1280"