I had a new experience with Kubernetes and Docker desktop. I might help you too. Kubernetes could not start according to the Desktop and it even went to red indicating that it failed. So I ran
kubectl get node
The node was ready, so I ran
kubectl get all --all-namespaces
Where I saw some pods could not start:
NAMESPACE NAME READY STATUS RESTARTS AGE
kube-system pod/coredns-6d4b75cb6d-nhxh4 1/1 Running 2 (6m25s ago) 51d
kube-system pod/coredns-6d4b75cb6d-x2q5r 1/1 Running 2 (6m25s ago) 51d
kube-system pod/etcd-docker-desktop 1/1 Running 2 (6m25s ago) 51d
kube-system pod/kube-apiserver-docker-desktop 1/1 Running 2 (6m25s ago) 51d
kube-system pod/kube-controller-manager-docker-desktop 1/1 Running 2 (6m25s ago) 51d
kube-system pod/kube-proxy-kx498 1/1 Running 2 (6m25s ago) 51d
kube-system pod/kube-scheduler-docker-desktop 1/1 Running 2 (6m25s ago) 51d
kube-system pod/storage-provisioner 0/1 Error 0 51d
kube-system pod/vpnkit-controller 0/1 ContainerStatusUnknown 1 (48d ago) 51d
Since no container was running in those pdos, I couldn’t have check the container logs, but I could check the description of those pods with the events:
kubectl describe -n kube-system pod/storage-provisioner
At the bottom of the output it was the end of the events:
Normal Started 48d kubelet Started container storage-provisioner
Warning Evicted 48d kubelet The node was low on resource: ephemeral-storage.
Normal Killing 48d kubelet Stopping container storage-provisioner
As you can see it was long time ago and there was no other events (just older). I could not start these pods so I did deleted them:
kubectl delete -n kube-system pod/storage-provisioner
kubectl delete -n kube-system pod/vpnkit-controller
There was nothing to recreate them like deployments, so I restarted Docker Desktop and Kubernetes was green again.
I remember there was a time when I didn’t have any free space because of one vulnerabilty checker Docker Desktop Extension that used about 40 gigabytes, and the last error message indicates that those containers stopped because of the lack of space, but I guess some other errors could happen too which causes some pods not to start, so next time you can check if kubernetes works but one or two pods can’t start so you can fix those and restart Docker Desktop.