在腾讯云上执行
一直抛错
I0626 11:20:46.944977 213753 round_trippers.go:553] GET https://公网 IP:6443/healthz?timeout=10s in 4 milliseconds
I0626 11:20:46.944977 213753 round_trippers.go:553] GET https://公网 IP:6443/healthz?timeout=10s in 4 milliseconds
I0626 11:20:46.944977 213753 round_trippers.go:553] GET https://公网 IP:6443/healthz?timeout=10s in 4 milliseconds
I0626 11:20:46.944977 213753 round_trippers.go:553] GET https://公网 IP:6443/healthz?timeout=10s in 4 milliseconds
查看 kubelet 初始化日志,发现是无法找到 master 节点
[root@master docker]# journalctl -xeu kubelet
Jun 26 11:23:45 master kubelet[213849]: E0626 11:23:45.843456 213849 kubelet.go:2424] "Error getting node" err="node \"master\" not found"
Jun 26 11:23:45 master kubelet[213849]: E0626 11:23:45.939644 213849 event.go:276] Unable to write event: '&v1.Event{TypeMeta:v1.TypeMeta{Kind:"", API>Jun 26 11:23:45 master kubelet[213849]: E0626 11:23:45.943806 213849 kubelet.go:2424] "Error getting node" err="node \"master\" not found"
Jun 26 11:23:46 master kubelet[213849]: E0626 11:23:46.044283 213849 kubelet.go:2424] "Error getting node" err="node \"master\" not found"
Jun 26 11:23:46 master kubelet[213849]: E0626 11:23:46.145039 213849 kubelet.go:2424] "Error getting node" err="node \"master\" not found"
Jun 26 11:23:46 master kubelet[213849]: E0626 11:23:46.245805 213849 kubelet.go:2424] "Error getting node" err="node \"master\" not found"
Jun 26 11:23:46 master kubelet[213849]: E0626 11:23:46.335784 213849 controller.go:144] failed to ensure lease exists, will retry in 7s, error: Get "h>Jun 26 11:23:46 master kubelet[213849]: E0626 11:23:46.346915 213849 kubelet.go:2424] "Error getting node" err="node \"master\" not found"
Jun 26 11:23:46 master kubelet[213849]: E0626 11:23:46.447024 213849 kubelet.go:2424] "Error getting node" err="node \"master\" not found"
Jun 26 11:23:46 master kubelet[213849]: I0626 11:23:46.468192 213849 kubelet_node_status.go:70] "Attempting to register node" node="master"
Jun 26 11:23:46 master kubelet[213849]: E0626 11:23:46.472694 213849 kubelet_node_status.go:92] "Unable to register node with API server" err="Post \">Jun 26 11:23:46 master kubelet[213849]: E0626 11:23:46.547873 213849 kubelet.go:2424] "Error getting node" err="node \"master\" not found"
master 是我本机的 hostname, /etc/hosts 也改成 master 指向公网 IP 了。 请问下大家是出了什么问题?
这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。
V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。
V2EX is a community of developers, designers and creative people.