Q.

Why is the POD in a pending state?

Inspect the environment for various kubernetes control plane components.

A.

Run the command: kubectl get pods --namespace kube-system  to see the status of scheduler  pod. We have removed the scheduler from this Kubernetes cluster. As a result, as it stands, the pod will remain in a pending state forever.

k describe pod nginx
k get pods --namespace kube-system

root@controlplane:~# cat nginx.yaml 
---
apiVersion: v1
kind: Pod
metadata:
  name: nginx
spec:
  containers:
  -  image: nginx
     name: nginx
  nodeName: node01