You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Kubernetes Dashboard Pod处于ContainerCreating状态无法运行求助

Hey there, let's work through this Kubernetes Dashboard pod stuck in ContainerCreating state together. I’ve run into similar issues plenty of times, so here’s a step-by-step troubleshooting guide to get you sorted:

1. First, Check the Pod's Detailed Events

The most straightforward way to find the root cause is to look at the pod's event history. Run this command:

kubectl describe pod kubernetes-dashboard-5bd6f767c7-v5g8q -n kube-system

Scroll down to the Events section—this will tell you exactly what’s going wrong:

  • If you see ImagePullBackOff or ErrImagePull, the dashboard image is failing to download
  • If there are errors related to volumes or network, that points to storage/CNI issues
  • Resource-related errors mean your node doesn’t have enough CPU/memory to run the pod
2. Verify Node Resource Availability

Sometimes the pod can’t start because the node is out of resources. Check your node’s resource usage with:

kubectl top nodes

Or get more detailed node info:

kubectl describe node <your-node-name>

If CPU/memory is maxed out, you’ll need to clean up unused pods on the node or add more nodes to your cluster.

3. Fix Image Pull Issues (Super Common!)

The default Kubernetes Dashboard image is hosted on Google’s registry, which can be slow or blocked in some regions. First, confirm the image your pod is trying to pull:

kubectl get pod kubernetes-dashboard-5bd6f767c7-v5g8q -n kube-system -o jsonpath='{.spec.containers[0].image}'

Try pulling this image manually on your node with docker pull <image-name>. If it fails, replace the image with a domestic mirror (like Alibaba Cloud’s). Update the deployment with:

# Replace the image tag with the one from your pod
kubectl set image deployment/kubernetes-dashboard kubernetes-dashboard=registry.cn-hangzhou.aliyuncs.com/google_containers/kubernetes-dashboard-amd64:v2.7.0 -n kube-system
4. Check Your CNI Network Plugin

If your cluster’s network plugin (like Flannel, Calico, or Weave) isn’t running properly, pods can’t get network interfaces and will stay stuck in ContainerCreating. Check the network pods:

kubectl get pods -n kube-system | grep -E 'flannel|calico|weave'

If any of these pods aren’t in Running state, fix the network plugin first—without working networking, most pods won’t start.

5. Dig Into Kubelet Logs

If none of the above works, check the kubelet logs on the node where the dashboard pod is scheduled. Kubelet handles pod creation and will log detailed errors:

# On systemd-based nodes
journalctl -u kubelet -f

Look for lines related to the dashboard pod—this will often reveal hidden issues like permission problems or storage mount failures.

Also, note that the kubectl logs error you’re seeing is expected: the pod hasn’t started its container yet, so there are no logs to retrieve. Always start with kubectl describe for stuck pods!

内容的提问来源于stack exchange,提问作者Snipper03

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.19 10:16:01