summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorMichal Cmarada <michal.cmarada@pantheon.tech>2018-06-15 13:38:44 +0200
committerMarek Gradzki <mgradzki@cisco.com>2018-06-15 11:44:05 +0000
commit14bc08567f3ec9afcc1e8b31e62fb43186f0c038 (patch)
treee15ba9c048dbb716b7f3d757fb2e55c4fc80a8b3 /examples
parent26ed56b66aa02845962b4d831e6a9a549876ad97 (diff)
Add configuration for mtu in docker examples
VPP is using mtu=9000 for interfaces that it creates. This fixes the mtu value for veth interfaces on linux side so they match the value configured in VPP for all veth interfaces in docker examples. Originally veth interfaces use smaller value since Linux automatically sets their MTU to be the smallest MTU of their slave ports. For VPP this means if a bigger frame is sent outside to the veth interface it will be dropped. Change-Id: I41117490ec80a0b2d2d2897493c2690f92766734 Signed-off-by: Michal Cmarada <michal.cmarada@pantheon.tech> (cherry picked from commit c6e27c7f0e1f1bc791878f3d0ca277500aad5fe6)
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/docker/utils.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/examples/docker/utils.sh b/examples/docker/utils.sh
index 7b4674752..91e18a6b6 100755
--- a/examples/docker/utils.sh
+++ b/examples/docker/utils.sh
@@ -59,5 +59,9 @@ function create_link {
# Bring interfaces up
ip netns exec $container1 ip link set $if1 up
ip netns exec $container2 ip link set $if2 up
+
+ # Set interfaces mtu to 9000 to match default VPP mtu values
+ ip netns exec ${container1} ifconfig ${if1} mtu 9000
+ ip netns exec ${container2} ifconfig ${if2} mtu 9000
echo "Link created successfully"
}