Mit vier Netzwerkkabeln vom Server zum Core-Switch und vom dem aus weiter mit jeweils 4 Kabeln zum nächsten …
apt-get install ifenslave-2.6 net-tools ethtool
Die /etc/network/interfaces dazu
# The loopback network interface
auto lo
iface lo inet loopback
# Erst alle echten Interfaces hochziehen
auto eth0
iface eth0 inet manual
bond-master bond0
auto eth1
iface eth1 inet manual
bond-master bond0
auto eth2
iface eth2 inet manual
bond-master bond0
auto eth3
iface eth3 inet manual
bond-master bond0
# Trunk0 / Bond0
auto bond0
iface bond0 inet manual
bond-slaves eth0 eth1 eth2 eth3
bond-mode 0
# VLAN FARBE INHALT
# 100 BLACK KABEL BW / Fritz BOX
# 101 GREY Infrastruktur (Switches etc.)
# 102 RED BELWUE Netze
# 20 BROWN VWNetz
# 40 GREEN paedagogisches Netz
# 41 BLUE WLAN public (päd. Netz)
# 50 PINK WLAN lehrer
# The LINK to BELWUE
auto bond0.102
iface bond0.102 inet static
address xxx.xx.xx.194
netmask 255.255.255.240
network xxx.xx.xx.192
broadcast xxx.xx.xx.207
gateway xxx.xx.xx.193
# dns-* options are implemented by the resolvconf package, if installed
dns-nameservers xxx.xx.xx.4
dns-search domain.tld
# iptables vorbereiten - evtl. unnoetig
up sysctl -w net.ipv4.ip_forward=1
up modprobe ip_tables iptable_nat
# Portweiterleitung von K9393 auf B443 fuer OMD
up iptables -t nat -A PREROUTING -p tcp -i bond0.102 --dport 9393 -j DNAT --to-destination 192.168.0.2:443
up iptables -A FORWARD -p tcp -d 192.168.0.2 --dport 9393 -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT
auto bond0.101
iface bond0.101 inet static
vlan-raw-device bond0
address 192.168.0.1
netmask 255.255.255.0
network 192.168.0.0
broadcast 192.168.0.255
dns-nameservers 127.0.0.1
dns-search grey
# add NAT / Masquerade for grey network
up sysctl -w net.ipv4.ip_forward=1
up modprobe ip_tables iptable_nat
up iptables -A FORWARD -o bond0.102 -i bond0.101 -s 192.168.0.0/24 -m conntrack --ctstate NEW -j ACCEPT
up iptables -A FORWARD -o bond0.102 -i bond0.101 -s 192.168.0.0/24 -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
up iptables -t nat -A POSTROUTING -o bond0.102 -j MASQUERADE
auto bond0.40
iface bond0.40 inet manual
vlan-raw-device bond0
up ifconfig $IFACE up
down ifconfig $IFACE down
auto bond0.41
iface bond0.41 inet manual
vlan-raw-device bond0
up ifconfig $IFACE up
down ifconfig $IFACE down
auto bond0.50
iface bond0.50 inet manual
vlan-raw-device bond0
up ifconfig $IFACE up
down ifconfig $IFACE down
auto bond0.20
iface bond0.20 inet manual
vlan-raw-device bond0
up ifconfig $IFACE up
down ifconfig $IFACE down
Im Switch die Trunks einrichten und die VLANs den Trunks zuweisen. Reboot. Tut.

Die zentralen Switches sind nun verkabelt und auch der Neubau hängt mit immerhin 2 Glasfasterleitungen an der Strippe.
Zuerst hatten wir Mode 4 eingerichtet. Die Geschwindigkeit war aber enttäuschend. Mit Round Robin / Mode 0 geht jetzt aber heftig mehr durch die Leitungen, wenn auch nicht das 4-fache. Außerdem: Einzelne Räume bleiben etwas magerer angebunden – z.B. der Neubau, der nun mit „nur“ 2 Glasfaserleitungen am Core-Switch hängt.

