k8wiz
Kubernetes
Easy
Commands

Which kubectl command would you use to view all pods in all namespaces?

Select your answer:

Show answer and explanation

Answer: kubectl get pods --all-namespaces

Explanation

The 'kubectl get pods --all-namespaces' command (or the shorter form 'kubectl get pods -A') lists all pods across all namespaces in the cluster, providing a cluster-wide view of running pods.

Read more about Kubernetes