802.1q setup to bridge interface

Hello David,

I also spent “some” time to have this working for us and came up with setting up our KVM servers like listed below.
I can’t tell for sure if this is the best solution (performance wise), as I still think I end up with too many layers of network abstractions, but so far is going well…

In your case, you should replace “bond0” by “eth0”, as we’re using LACP port aggregation for high-availability. (This is Ubuntu 16.04 LTS, by the way.)

/etc/network/interfaces:

auto eno2
iface eno2 inet manual
bond-master bond0

eno3 configuration

auto eno3
iface eno3 inet manual
bond-master bond0

bond0 configuration

It uses standard IEEE 802.3ad LACP bonding protocol

auto bond0
iface bond0 inet manual
bond-slaves eno2 eno3
bond-mode 4
bond-miimon 100
bond-lacp-rate fast
bond-downdelay 0
bond-updelay 0
bond-xmit_hash_policy 1

local interface for vlan 481

auto bond0.481
iface bond0.481 inet static
vlan-raw-device bond0

bridge for vlan 481

auto br481
iface br481 inet static
bridge_ports bond0.481
address xxx.yyy.zzz.ccc
network xxx.yyy.zzz.0
netmask 255.255.255.0
broadcast xxx.yyy.zzz.255
gateway xxx.yyy.zzz.254
dns-nameservers xxx.yyy.zzz.bbb
dns-search example.com
bridge_hello 2
bridge_maxage 12
bridge_stp off
bridge_fd 9

Bottom line, I created a tagged virtual interface on top of the physical interface and then associated the tagged virtual interface to the bridge.

Then, on OpenNebula, I created a 802.1q vNet where I set the bridge to “br481” and did not specify a physical device for it.

Hope this help,

Alex