I have a single server attached to the internet on a public IP.
I have 4 different VM's attached to vmbr1. Their Ip's are 10.0.0.101, 10.0.0.102, 10.0.0.103 and 10.0.0.104. Gateway 10.0.0.254 for all of them.
I cannot make then go to the internet. They cannot ping 8.8.8.8 or any other internet address,
/etc/network/interfaces:
auto lo
iface lo inet loopback
auto eno1
iface eno1 inet manual
auto eno2
iface eno2 inet manual
auto vmbr0
iface vmbr0 inet static
address 140.221.22.23/24
gateway 140.221.22.254
bridge-ports eno1
bridge-stp off
bridge-fd 0
hwaddress A4:BF:01:1E:58:48
auto vmbr1
iface vmbr1 inet static
address 10.0.0.254/24
bridge-ports none
bridge-stp off
bridge-fd 0
post-up echo 1 > /proc/sys/net/ipv4/ip_foward
post-up iptables -t nat -A POSTROUTING -s '10.0.0.0/24' -o eno1 -j MASQUERADE
post-up iptables -t nat -D POSTROUTING -s '10.0.0.0/24' -o eno1 -j MASQUERADE
post-up iptables -t raw -I PREROUTING -i fwbr+ -j CT --zone 1
post-down iptables -t raw -D PREROUTING -i fwbr+ -j CT --zone 1
Questions:
a) What am I missing here to make it work?
b) I need to bond eno1 and eno2? What is the correct way of doing it?
I have 4 different VM's attached to vmbr1. Their Ip's are 10.0.0.101, 10.0.0.102, 10.0.0.103 and 10.0.0.104. Gateway 10.0.0.254 for all of them.
I cannot make then go to the internet. They cannot ping 8.8.8.8 or any other internet address,
/etc/network/interfaces:
auto lo
iface lo inet loopback
auto eno1
iface eno1 inet manual
auto eno2
iface eno2 inet manual
auto vmbr0
iface vmbr0 inet static
address 140.221.22.23/24
gateway 140.221.22.254
bridge-ports eno1
bridge-stp off
bridge-fd 0
hwaddress A4:BF:01:1E:58:48
auto vmbr1
iface vmbr1 inet static
address 10.0.0.254/24
bridge-ports none
bridge-stp off
bridge-fd 0
post-up echo 1 > /proc/sys/net/ipv4/ip_foward
post-up iptables -t nat -A POSTROUTING -s '10.0.0.0/24' -o eno1 -j MASQUERADE
post-up iptables -t nat -D POSTROUTING -s '10.0.0.0/24' -o eno1 -j MASQUERADE
post-up iptables -t raw -I PREROUTING -i fwbr+ -j CT --zone 1
post-down iptables -t raw -D PREROUTING -i fwbr+ -j CT --zone 1
Questions:
a) What am I missing here to make it work?
b) I need to bond eno1 and eno2? What is the correct way of doing it?