Study FAQ
How do ClusterIP and LoadBalancer Services differ in VKS?
Also asked as 2
- When does a Kubernetes Service need an external VIP in VKS?
- What changes when I use a LoadBalancer Service instead of ClusterIP in VKS?
Answer
In a VKS workload cluster, a ClusterIP Service provides a stable internal address, while a LoadBalancer Service requests external exposure through an integrated provider. On VCF 9.0, the available provider and VIP behavior depend on the configured topology and load-balancer integration.
A typical selector-based Service points to Pods through EndpointSlices. Its Service port is the client-facing port, while targetPort must match the application listener on the backends. A LoadBalancer Service also needs a provider to allocate and publish an address and route traffic toward its backends. Check status.loadBalancer.ingress for the assigned address. That status does not establish reachability from every network.
Use ClusterIP for cluster-internal clients. Use a supported LoadBalancer exposure when external clients need the Service directly and routing and firewall policy permit it. An HTTP or HTTPS ingress controller can also be exposed through a LoadBalancer Service and apply host and path routing for multiple backend Services.
Official references
Full explanation
How Load Balancing, Ingress, Egress, CNI, and Service Mesh Work in VKS
Study guide · 3V0-24.25
Read the full explanation