I want to create two bridges with two upstream WAN interfaces. Virtual Machines connected to the bridges should be able to communicate with each other, but each bridge would have a different WAN interface.
Bridge 1 (br1)'s traffic headed to the Internet would exit out of ens3, Bridge 2 (br2)'s traffic headed to the Internet would exit out of ens4.
So far, I have attempted to do this setup with systemd-networkd, with no success. I am using VLAN because attaching the WAN interface ens3 to any bridge kills my internet connection. With the below setup, VM's connected to that bridge can ping each other and the gateway IP, but they cannot access the internet.
Are there any configuration changes or iptables rules I can add to fix this problem? IF having two bridges with different upstream WAN interfaces is impossible with systemd-networkd, are there other solutions that can do this?
Here are the configuration files for Bridge 1:
[Match] Name=ens3 [Network] DNS=18.104.22.168 DNS=22.214.171.124 NTP=pool.ntp.org VLAN=br1vlan [Address] Address=(wan ip of ens3)/24 [Route] Gateway=(wan gateway of ens3)
Name=br1vlan [Network] Bridge=br1
[Match] Name=br1 [Network] IPv6AcceptRA=false IPForward=yes IPMasquerade=yes DNS=10.1.0.1 Address=10.1.0.10/24 Gateway=10.1.0.1
and here are the configuration files for Bridge 2:
[Match] Name=ens4 [Network] DNS=126.96.36.199 DNS=188.8.131.52 NTP=pool.ntp.org VLAN=br2vlan [Address] Address=(wan ip of ens4)/24 [Route] Gateway=(wan gateway of ens4)
[Match] Name=br2vlan [Network] Bridge=br2
[Match] Name=br2 [Network] IPv6AcceptRA=false IPForward=yes IPMasquerade=yes DNS=10.2.0.1 Address=10.2.0.10/24 Gateway=10.2.0.1