Recently I found that sometimes kubernetes pods are not starting. They were failing
UnexpectedAdmissionError. Time to deep dive into what may cause it.
After searching through the kubernetes codebase I found several places where this status was set.
As of Kubernetes 1.19, this error will be set in the following cases:
In my particular case it was caused by CPU Manager - there were CPU and Memory to admit the pod, but it was not possible to give the pods exclusive number of CPUs.