kubectl get pods --field-selector=status.phase=Running

Category: Kubernetes & Containers

kubectl get pods --field-selector=status.phase=Running

Filter pods by a field value

Filters the pod list by any field in the pod object, here only pods whose phase is Running. Field selectors work on other resources too, for example spec.nodeName=node-a. Use kubectl explain pods.spec to discover field names.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.