部署一个 Deployment 后 Pod 一直是 Pending,events 里看到:
0/3 nodes are available: 3 node(s) had taints that the pod didn't tolerate.
master 节点有 NoSchedule 污点,但我的 work 节点应该没有啊?
部署一个 Deployment 后 Pod 一直是 Pending,events 里看到:
0/3 nodes are available: 3 node(s) had taints that the pod didn't tolerate.
master 节点有 NoSchedule 污点,但我的 work 节点应该没有啊?
先执行 kubectl describe node <node> | grep -i taint 看看具体污点。
常见情况:worker 节点被打了 node-role.kubernetes.io/control-plane 或者自定义污点。
查到了,worker 节点有 dedicated=gpu:NoSchedule,之前测试留下的。
去掉即可:
kubectl taint nodes <node> dedicated=gpu:NoSchedule-
注意最后的减号。