Hi, just sharing my config for others to use as a reference. It took me a while to get this going.
I have three network interfaces, for my setup I wanted 802.3ad/LACP bonding plus two bridge interfaces.
- eth0,eth2 are bonded (bond0) and connected to my lab network
- eth1 not bonded and connected to my homenetwork
- labbr0 bridge interface connected to bond0
- hombr0 bridge interface connected to eth1
I have Cisco SG 200-18 18-Port Gigabit Smart Switch configured correctly for eth0 and eth2.
I did configure bonding via Openmediavault admin console, then I lock the network file with the "chattr" command so that Openmediavault cannot modify my changes.
chattr +i /etc/network/interfaces
And the contents of that file.
$ cat /etc/network/interfaces
# The loopback network interface
auto lo
iface lo inet loopback
iface lo inet6 loopback
# Network interfaces
allow-hotplug eth0
iface eth0 inet manual
pre-up ifconfig $IFACE up
pre-down ifconfig $IFACE down
allow-hotplug eth1
iface eth1 inet manual
pre-up ifconfig $IFACE up
pre-down ifconfig $IFACE down
allow-hotplug eth2
iface eth2 inet manual
pre-up ifconfig $IFACE up
pre-down ifconfig $IFACE down
# bond0 network interface
auto bond0
iface bond0 inet manual
bond-slaves eth0 eth2
bond-primary eth0
bond-mode 4
bond-miimon 100
bond-downdelay 200
bond-updelay 200
iface bond0 inet6 manual
pre-down ip -6 addr flush dev bond0
# homenet bridge on eth1 HOMENET NEtwork
auto hombr0
iface hombr0 inet static
address 192.168.10.5
gateway 192.168.10.1
netmask 255.255.255.0
dns-nameservers 8.8.8.8
bridge_ports eth1
bridge_fd 0
bridge_hello 0
bridge_maxage 0
bridge_stp on
bridge_waitport 0
# labnet bridge on eth1 LABNET Network
auto labbr0
iface labbr0 inet static
address 192.168.40.4
gateway 192.168.40.1
netmask 255.255.255.0
dns-nameservers 8.8.8.8
bridge_ports bond0
bridge_fd 0
bridge_hello 0
bridge_maxage 0
bridge_stp on
bridge_waitport 0