k8s should traffic goes to master nodes or worker nodes?

Should traffic from clients (outside world) to service inside k8s comes in through master nodes or worker nodes? and why?

From what i seen so far, docs are always showing LB pools consisting of master nodes instead of worker nodes. is there a reason for this?

in a big bluster, would it be more beneficial to send all traffic to a few designated worker nodes?

for example: let say my k8s cluster has 2 master nodes, 4 worker nodes, and an external load balancer. most examples out there load balance incoming traffic to the 2 master nodes instead of the 4 worker nodes. why is this? is there a reason in term of efficiency/performance?

please advise. thank you.

1 answer

  • answered 2018-03-14 02:49 Vijay

    What do you mean the traffic goes through worker nodes or master node? You expose your service in the pods to the outside world via NodePort or LoadBalancer. So who ever hits the LoadBalancer or reach the node on a particular port would be redirected to the corresponding service.