Why do my load balancer's Kubernetes node(s) have the No Traffic status?

If your node’s status is showing as “No Traffic”, the Kubernetes service’s externaltrafficpolicy setting could be rejecting the load balancer’s health checks. This setting describes how nodes should respond to health checks from an external load balancer and can make nodes appear with the “No Traffic” status if not set appropriately.

Most likely, your nodes are configured to reject health checks if they do not have a pod for that service running locally. If a node rejects a health check for a service, the load balancer shows the node status as “No Traffic” in the DigitalOcean Control Panel.

The service’s externaltrafficpolicy setting affects how nodes respond to these health checks when set with the following values:

  • Local - Any node not directly hosting a pod for that service rejects the request. To the load balancer, the request was rejected and therefore the node shows as “No Traffic”. Kubernetes considers these nodes healthy, but they do not field traffic for this service through the LoadBalancer.

  • Cluster - Nodes forward traffic to other nodes that are hosting pods for the service. Since the nodes are allowed to pass the traffic to other nodes, all of the node become valid endpoints as long as one pod is healthy.

To update this setting for a service, use the following command substituting <traffic-policy-value> for Local or Cluster:

kubectl patch svc <your-service> -p '{"spec":{"externalTrafficPolicy":"<traffic-policy-value>"}}'

If using the Cluster setting, the original client IP address is lost due to this extra network hop. To ensure fewer network hops, use the Local setting. For more information on externaltrafficpolicy, see the official Kubernetes documentation .

Load balancers return 503 errors when there are either no Droplets assigned to them or all of the assigned Droplets are unhealthy.