Overview - TCP probe configuration
What is it?
A TCP probe in Kubernetes is a way to check if a container is ready or alive by trying to open a TCP connection on a specific port. It does not send any data but simply tests if the port is open and accepting connections. This helps Kubernetes know if the application inside the container is working properly or needs restarting. TCP probes are simpler than HTTP probes and useful for services that do not speak HTTP.
Why it matters
Without TCP probes, Kubernetes would not know if a container is actually ready to serve traffic or if it has crashed or hung. This could lead to sending requests to broken services, causing downtime or errors. TCP probes help maintain application reliability by allowing Kubernetes to restart or stop sending traffic to unhealthy containers automatically.
Where it fits
Before learning TCP probes, you should understand basic Kubernetes concepts like pods, containers, and the idea of health checks (probes). After mastering TCP probes, you can learn about other probe types like HTTP and command probes, and how to combine them for robust application monitoring.