Hello team~. I need help so this is my first question.
We are in a situation where we need to conclude whether it is possible to cluster nodes in two different network zones.
-
situation
There is a master node and several worker nodes in the A network zone, and this time, a new worker node (VM) in the B network zone must be joined.Zones A and B cannot communicate with each other through private IPs, and can communicate with new worker nodes (VMs) through NAT port mapping (PAT) on the router in zone B.
Additionally, new worker nodes do not have their own public IP network interface.
To link the new worker node in Zone B, the router was set up as follows.
-
Network B zone router PAT settings with new worker nodes
router public IP:18801 > new worker node private IP:22
router public IP:10251 > new worker node private IP:10250
router public IP:38091 > new worker node private IP:8899
… -
Setting environment for node join in k8s
- I set the router public IP and mapping port (18801) for ssh connection to the new node in ssh_config.
- We set the new worker node name and router public IP in hosts.
- In inventory.ini, ansible_port of the new worker node is set to the router mapping port (18801).
-
result
In this setting, linking of the new worker node through join was successful.
CNI uses calico, and the internal IP of the new worker node is recognized as private IP.
Pod creation and deletion via kubectl is working.
However, viewing pod logs of new nodes and communication between pods through kubectl are not working. -
enquiry
1) If there is a worker node that cannot communicate internally with the master node and other existing worker nodes, is it possible to link it using an external public IP (router)?
2) For this, what should I do?
We are conducting various tests, but integration is failing.
We need your help.
thanks.