kubernetes仪表板显示http:代理错误:拨打tcp [:: 1]:8080:connect:连接被拒绝 [英] kubernetes dashboard showing http: proxy error: dial tcp [::1]:8080: connect: connection refused

查看:288
本文介绍了kubernetes仪表板显示http:代理错误:拨打tcp [:: 1]:8080:connect:连接被拒绝的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我安装了kubeadm来部署多节点kubernetes集群.添加了两个节点.准备好了我可以使用节点端口服务运行我的应用程序.当我尝试哟时,访问仪表板时遇到了问题. 我正在按照链接

I installed kubeadm to deploy multi node kubernetes cluster. Added two nodes. Those are ready. I am able to run my app using node port service. While i am trying yo access the dashboard facing an issue. I am following the steps to install dashboard in this link

kubectl create -f https://raw.githubusercontent.com/kubernetes/dashboard/master/src/deploy/recommended/kubernetes-dashboard.yaml

dash-admin.yaml:
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
   name: kubernetes-dashboard
   labels:
     k8s-app: kubernetes-dashboard
roleRef:
   apiGroup: rbac.authorization.k8s.io
   kind: ClusterRole
   name: cluster-admin
subjects:
- kind: ServiceAccount
   name: kubernetes-dashboard
   namespace: kube-system

kubectl create -f dashboard-admin.yaml

nohup kubectl proxy --address="172.20.22.101" -p 443 --accept-hosts='^*$' &

运行良好,并将输出保存在nohup.out

Its running well and saving the output in nohup.out

当我尝试使用url:172.20.22.101:443/api/v1/namespaces/kube-system/services/….访问该网站时,它显示为connection refused. 我在nohup.out中观察到输出,它显示以下错误:

When i try to access the site using the url: 172.20.22.101:443/api/v1/namespaces/kube-system/services/…. it's showing connection refused. I observed the output in the nohup.out, it's showing the below error:

I1203 12:28:05.880828 15591 log.go:172] http:代理错误:拨打tcp [:: 1]:8080:连接:连接被拒绝–

I1203 12:28:05.880828 15591 log.go:172] http: proxy error: dial tcp [::1]:8080: connect: connection refused –

推荐答案

您没有以root或sudo权限运行它.

You are not running it with root or sudo permission.

在使用root运行后,我遇到了此问题.我能够毫无错误地访问它.

I have encountered this issue, and after running using root. I was able to access it with no errors.

这篇关于kubernetes仪表板显示http:代理错误:拨打tcp [:: 1]:8080:connect:连接被拒绝的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆