In Kubernetes, what is a service called when it is created without a ClusterIP?

Study for the Kubernetes Certified Network Administrator Exam. Our test offers comprehensive flashcards, multiple-choice questions, and detailed explanations. Be confident for your exam!

Multiple Choice

In Kubernetes, what is a service called when it is created without a ClusterIP?

Explanation:
Headless Service. In Kubernetes, a service normally gets a ClusterIP—a virtual IP that load-balances traffic to the backing pods. When a service is created without a ClusterIP (spec.clusterIP set to None), Kubernetes does not allocate that virtual IP. Instead, DNS for the service resolves to the actual pod endpoints, so clients can connect directly to the individual pods (often via multiple A records or SRV records for the ports). This is useful for stateful workloads or when direct pod discovery is required, while the service still provides a stable DNS name and port.

Headless Service. In Kubernetes, a service normally gets a ClusterIP—a virtual IP that load-balances traffic to the backing pods. When a service is created without a ClusterIP (spec.clusterIP set to None), Kubernetes does not allocate that virtual IP. Instead, DNS for the service resolves to the actual pod endpoints, so clients can connect directly to the individual pods (often via multiple A records or SRV records for the ports). This is useful for stateful workloads or when direct pod discovery is required, while the service still provides a stable DNS name and port.

Subscribe

Get the latest from Passetra

You can unsubscribe at any time. Read our privacy policy