Cluster information:
Kubernetes version: 1.28.2
Cloud being used: bare-metal
Installation method: def
Host OS: CentOS 8
CNI and version: Calico
Hi All!
I have problem which is interesting, at least for me. But I can’t find a solution for that. I have a K8S cluster with one master and 2 worker nodes. On this cluster I use Calico CNI and deployed Traefik ingress controller exposed to outside world through a NodePort
I’ve already raised another topic about my main problem (NodePort service is not working from Master) but I have a second one too.
I deployed a simple whoami
application with one replica. If I try to access the whoami pod using the Traefik ingress like this: curl http://node1:32000/whoamitest
it always goes to time out for the first try. But when I try to access that resource targeting the other worker node: curl http://node2:32000/whoamitest
, I get the response what I expect.
And here it comes the interesting part… If I try to access the service again from node1
, it work fine. If I keep using any of the nodes it still works fine. But when I take a break and don’t use the service for a few minutes, the whole thing starts from the beginning. The call times out for the first try, but if I try it again on the other node it starts to work as expected again.
As I experienced, this behaviour is not depending on which node I try first, and neither depending on which node runs the whoami
pod.
Have you ever seen this weird behaviour before? Did you manage to overcome it somehow?
Every help is highly appreciated!