Sorry if this has been asked before, but I couldn’t find anything…
I’m running multiple containers on a server. Since the ISP doesn’t allow me to use mutliple mac addresses, I’m using a routed setup. Each container has its own profile like this:
devices: eth0: ipv4.address: 220.127.116.11 nictype: routed type: nic
This works perfectly well for almost everything I need, but there is one issue:
Some of the containers are in the same subnet and therefore have consecutive IP addresses. Say 18.104.22.168, 22.214.171.124, 126.96.36.199, 188.8.131.52.
While e.g. .4 and .7 can communicate just fine, .4 and .5 can’t, .5 and .6 can’t, etc.
I think this is because .5 seems to be the broadcast address of .4.
If I am inside 184.108.40.206 and run
ping 220.127.116.11, I get an error like this:
Do you want to ping broadcast? Then -b. If not, check your local firewall rules.
And when checking with
ip addr, indeed this is the broadcast address:
inet 18.104.22.168/32 brd 22.214.171.124 scope global eth0
Is there any simple way to fix this? Right now, sadly, two discourse instances can’t access my mail server to send emails because they are its IP-neightbours…
Note: There are also containers on the host with completely different IPs. But some of them are consecutive.