Containers on two hosts on different subnets cannot talk to each other

Hello,

Here’s the scenario I have:

  • One AWS VPC with CIDR block 172.17.0.0/16. Any host in the VPC can talk to any host regardless of subnet.
  • One host in public subnet 172.17.0.0/24
  • One host in private subnet 172.17.100.0/24
  • Both hosts can ping each other without any problems

I deployed a container to each host, but the containers can’t talk to each other. When I tried to do a ping, it hangs.

Any suggestions would be appreciated.

Thanks

Are you sure they are able to talk over UDP ports 500 and 4500? Also, can you spin up 2 containers on each host? There is a known networking issue that sometimes networking doesn’t get set up when you have only 1 container.

https://github.com/rancher/rancher/issues/486

Hi Denise,

Thanks for your response. I couldn’t figure out the exact problem, but after removing and adding back the hosts to rancher, I’m able to ping the containers correctly. It may be related to the issue described on the rancher issue you mentioned.

Thanks