mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-11-26 19:35:10 +00:00
This patch adds a check for the static policy state validation. The check fails if the CPU topology obtained from cadvisor doesn't match with the current topology in the state file. If the CPU topology has changed in a node, cpu manager static policy might try to assign non-present cores to containers. For example in my test case, static policy had the default CPU set of 0-1,4-7. Then kubelet was shut down and CPU 7 was offlined. After restarting the kubelet, CPU manager tries to assign the non-existent CPU 7 to containers which don't have exclusive allocations assigned to them: Error response from daemon: Requested CPUs are not available - requested 0-1,4-7, available: 0-6) This breaks the exclusivity, since the CPUs from the shared pool don't get assigned to non-exclusive containers, meaning that they can execute on the exclusive CPUs.