]> git.proxmox.com Git - mirror_lxc.git/commit
set the mtu before attaching to the bridge
authorDaniel Lezcano <dlezcano@fr.ibm.com>
Thu, 26 Mar 2009 10:32:23 +0000 (11:32 +0100)
committerDaniel Lezcano <dlezcano@fr.ibm.com>
Thu, 26 Mar 2009 10:32:23 +0000 (11:32 +0100)
commiteb14c10a414bcbb39cc29ebc82f5299aa36b6c30
treec9a0af3465e7c18ade1ab84d7c0e948da06692af
parent497353b66b504f12cf8b6e166bba7cb309486dc3
set the mtu before attaching to the bridge

"I checked lxc-0.6.1 and your commit 75d09f83b82f35a610f4922e06ad897692062fab
(set mtu for netdev).

I found a problem of the MTU size of br0.  In the current code,
device_set_mtu() is
called after bridge_attach(), so the MTU size of br0 is set to the
default MTU size
of veth0 (i.e., 1500 bytes).
This causes performance degradation as I reported.

We need to modify to call device_set_mtu() before bridge_attach()"

Now that we have the network functions accessible, do not longer
use the lxc_configure_veth, lxc_configure_macvlan and split
the configuration of the veth in order to create it, configure it
and finally attach it to the bridge.

Reported-by: Ryousei Takano <takano-ryousei@aist.go.jp>
Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
Acked-by: Ryousei Takano <takano-ryousei@aist.go.jp>
src/lxc/lxc_conf.c
src/lxc/network.c
src/lxc/network.h