2016-12-29 88 views
0

我是kubernetes新手。我剛纔遵循這個指南,有一個流浪漢/ kubernetes集羣:https://coreos.com/kubernetes/docs/latest/kubernetes-on-vagrant.htmlkubernetes儀表板不可用後羣集部署

我很感興趣查看UI,所以我在這裏遵循的指示:http://kubernetes.io/docs/user-guide/ui/#deploying-the-dashboard-ui

$ kubectl proxy 
Starting to serve on 127.0.0.1:8001 

在瀏覽到上述IP:PORT,供應<h3>Unauthorized</h3>。所以,我後綴/ui的URI,我們得到:

// 127.0.0.1:8001/ui redirected to http://localhost:8001/api/v1/proxy/namespaces/kube-system/services/kubernetes-dashboard 
{ 
    "kind": "Status", 
    "apiVersion": "v1", 
    "metadata": {}, 
    "status": "Failure", 
    "message": "no endpoints available for service \"kubernetes-dashboard\"", 
    "reason": "ServiceUnavailable", 
    "code": 503 
} 

也許相關的是:

$ kubectl cluster-info 
Kubernetes master is running at https://172.17.4.101:443 
Heapster is running at https://172.17.4.101:443/api/v1/proxy/namespaces/kube-system/services/heapster 
KubeDNS is running at https://172.17.4.101:443/api/v1/proxy/namespaces/kube-system/services/kube-dns 
kubernetes-dashboard is running at https://172.17.4.101:443/api/v1/proxy/namespaces/kube-system/services/kubernetes-dashboard 

$ kubectl get services 
NAME   CLUSTER-IP EXTERNAL-IP PORT(S) AGE 
kubernetes 10.3.0.1  <none>  443/TCP 36m 

我看到了另一個SO線程,Kubernetes dashboard keeps pending with message: no endpoints available for service "kubernetes-dashboard",並發現get podsdescribe pod <pod-name> --namespace=kube-system

所以,我跑kubectl describe pod kubernetes-dashboard-3543765157-94gj9 --namespace="kube-system"其產生:https://gist.github.com/cdaringe/b972bf5a95c9f2a7cb8386ef6bf2252b

回答

0

最終,我的羣集沒有節點,所以UI服務沒地方降落,並運行! API仍然嘗試代理它,這就是爲什麼它報告「沒有端點」 - 沒有主機端點提供內容。還沒有弄清楚爲什麼我的流浪羣集沒有部署節點。我會猜測,工人們從未下載過Kubelet並加入。

+0

我想你可以把這個標記爲已解決然後... – luxas