Talk:LXD configuration for OSM Release THREE
From OSM Public Wiki
For the MTU configuration after LXD configuration I propose user to run the following:
# get main interface MTU DEFAULT_INTERFACE=$(route -n | awk '$1~/^0.0.0.0/ {print $8}') DEFAULT_MTU=$( ip addr show $DEFAULT_INTERFACE | grep -i -E "(MTU|mtu)(:| +)[0-9]+" -o | grep -E "[0-9]+" -o ) # set lxc MTU if diferent from 1500 [ "$DEFAULT_MTU" -ne 1500 ] && lxc profile device set default eth0 mtu $DEFAULT_MTU
Not needed to set mtu of lxdbr0 mtu xxxx. Just editing lxc default profile is enough and it is permanent
---
This is the new MTU section
MTU
Check the MTU of the LXD bridge (lxdbr0) and the MTU of the default interface. If they are different, change the default MTU of the containers. This might be required, for instance, when running OSM in a VM on some Openstack distributions.
Note: In this example, we will assume that the default interface is ens3 and its MTU is 1446
lxc list # This will drive initialization of lxdbr0 ip address show ens3 # In case ens3 is the default interface ip address show lxdbr0 sudo lxc profile device set default eth0 mtu 1446 # Use the appropriate MTU value