I have a question : when we use kubectl -n kube-system get pods, we get all the . . .

Aishwarya koparde:
I have a question : when we use kubectl -n kube-system get pods, we get all the pods listed. so before this i got one practice question in which i need to create a new pod named nginx and schedule it on node 02. when i am checking the nginx pod, it is available in the command kubectl get pods, and not in kubectl -n kube-system get pods?

Marwan Tawashi:
What is your default namespace when you run kubectl get pods?

Marwan Tawashi:
If you are running any kubectl command without the -n then it will run against the default namespace which can be configured using kubectl config set-context --namespace