node节点加入k8s集群时报错:no such host

  • Post author:
  • Post category:其他


向集群添加新节点,在node节点执行

kubeadm init

输出的

kubeadm join

命令时,报错:error execution phase preflight: couldn’t validate the identity of the API Server: Get https://k8s-vip:16443/api/v1/namespaces/kube-public/configmaps/cluster-info?timeout=10s: dial tcp: lookup k8s-vip on 8.8.8.8:53: no such host

在这里插入图片描述

这时候,只需要将node1节点里的hosts表里的内容保持与master节点一致就可以。

在这里插入图片描述

再次执行即可,加入成功。

在这里插入图片描述

在这里插入图片描述



版权声明:本文为weixin_64124795原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。