Courseiva
Application Observability and MaintenanceeasyMultiple ChoiceObjective-mapped

CKAD Application Observability and Maintenance Practice Question

Which kubectl command streams logs from a pod named 'web-pod' in real-time?

⚠ Common exam trap

Test-takers frequently confuse flags like `--tail` or `--since` with real-time streaming, not realizing that only `-f` (or `--follow`) provides continuous log output.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

kubectl logs -f web-pod

The `-f` flag (short for `--follow`) tells kubectl to stream logs from the pod in real-time, similar to `tail -f` on a file. This is essential for live monitoring of application output as it is generated.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • kubectl logs --since=5m web-pod

    Why it's wrong here

    This shows logs from the last 5 minutes and exits.

  • kubectl logs --tail=100 web-pod

    Why it's wrong here

    This outputs the last 100 lines and exits.

  • kubectl logs -f web-pod

    Why this is correct

    The -f flag streams logs in real-time.

  • kubectl logs web-pod

    Why it's wrong here

    This outputs logs and exits, does not stream.

About these practice questions

One of 160 original CKAD practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This CKAD practice question is part of Courseiva's free CNCF certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the CKAD exam.