Study. uk . com
  1. Home
  2. All questions
  3. Question 915

CKA study material · question 915 of 1000

Which of these is a valid target for kubectl logs?

  1. node/worker-1
  2. service/web
  3. namespace/prod
  4. deployment/nginx
Show the answer

Answer: D. deployment/nginx

kubectl logs accepts a Pod or a controller such as a Deployment, from which it selects Pods. Nodes, Services and namespaces are not log sources.

Source: kubectl logs (Kubernetes) — Synopsis

Challenge yourself on this topic → Study as cards