共计 1256 个字符,预计需要花费 4 分钟才能阅读完成。
查看
kubectl get pod -A
个别状况都是 kubernetes-dashboard 命名空间下的容器镜像拉取出错
NAMESPACE NAME READY STATUS RESTARTS AGE
kube-system coredns-65c54cc984-4km8g 1/1 Running 0 101s
kube-system etcd-minikube 1/1 Running 0 112s
kube-system kube-apiserver-minikube 1/1 Running 0 112s
kube-system kube-controller-manager-minikube 1/1 Running 0 112s
kube-system kube-proxy-6vxh7 1/1 Running 0 101s
kube-system kube-scheduler-minikube 1/1 Running 0 112s
kube-system storage-provisioner 1/1 Running 1 (70s ago) 109s
kubernetes-dashboard dashboard-metrics-scraper-7db978b848-wpxd4 0/1 ImagePullBackOff 0 100s
kubernetes-dashboard kubernetes-dashboard-6f4c897964-z7672 0/1 ImagePullBackOff 0 100s
查看日志
kubectl describe pod dashboard-metrics-scraper-7db978b848-wpxd4 -n kubernetes-dashboard
能够看到镜像下载出错了,而后始终重试
Back-off pulling image "kubernetesui/metrics-scraper:v1.0.4"
Error: ImagePullBackOff
手动下载
minikube ssh
咱们先从国内库下载镜像,再打上 tag
# 手动 pull
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/metrics-scraper:v1.0.4
#打上 tag
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/metrics-scraper:v1.0.4 docker.io/kubernetesui/metrics-scraper:v1.0.4
# 手动 pull
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/dashboard:v2.0.3
#打上 tag
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/dashboard:v2.0.3 kubernetesui/dashboard:v2.0.3
实现
minikube dashboard
正文完