Easy1 markMultiple Choice

GCP ACE · Question 34 · Domain 4.2: Managing GKE resources

You are troubleshooting an application running on Google Kubernetes Engine (GKE). You need to see a list of all currently running pods in the default namespace.

Which command should you use?

Answer options:

A.

kubectl get pods

B.

gcloud container pods list

C.

kubectl describe cluster

D.

gcloud compute pods list

How to approach this question

Remember that once a GKE cluster is running, you use standard Kubernetes commands to interact with its resources.

Full Answer

A.kubectl get pods✓ Correct
To view the inventory of running resources inside a Kubernetes cluster (like pods, services, deployments), you use the `kubectl` command-line tool. The command `kubectl get pods` lists all pods in the current active namespace.

Common mistakes

Trying to use `gcloud` to list Kubernetes-specific resources.

Practice the full GCP Associate Cloud Engineer Practice Exam 5

50 questions · hints · full answers · grading

More questions from this exam