Certified Kubernetes Application Developer (CKAD) Practice Test

Disable ads (and more) with a membership for a one time $2.99 payment

Enhance your skills for the CKAD exam. Study with curated quizzes and detailed explanations. Prepare effectively for your success!

Each practice test/flash card set has 50 randomly selected questions from a bank of over 500. You'll get a new set of questions each time!

Practice this question and more.


Which type of probe can run commands directly inside the container?

  1. httpGet

  2. tcpSocket

  3. exec

  4. none

The correct answer is: exec

The correct answer is "exec," as this type of probe is designed to run commands directly within the container's environment. The exec probe allows Kubernetes to execute a specified command inside the container, enabling the system to assess the container's health based on the command's exit status. If the command returns a successful exit code (typically 0), the container is considered healthy. In contrast, the other options do not allow for direct execution of commands inside the container. The httpGet probe checks the health of a container by making an HTTP GET request to a specified endpoint; it evaluates the response status code to determine health. The tcpSocket probe tests connectivity by initiating a TCP connection to a specified port on the container, but it does not execute commands. The option "none" is not applicable since there is indeed a probe type that executes commands. This understanding of probes is crucial in Kubernetes, as they help ensure that applications are running correctly and can recover from failures. Knowing the specific capabilities of each probe type will help in making informed decisions for monitoring and maintaining application health in a Kubernetes environment.