k8s Could not find a JWS signature in the cluster-info ConfigMap for token ID “*****”
这个错误的原因是没有token
kubeadm join —
error execution phase preflight: couldn’t validate the identity of the API Server: abort connecting to API servers after timeout of 5m0s
这个错误的原因是token失效
两种方案都需要重新生成token
kubeadm join报错及解决
error的原因: 是master生成的节点不存在或者过期了.
解决方案: 重新生成
查看token状态
TTL值 就是token生于时间
[root@k8s-master ~]# kubeadm token list
重新生产token
[root@k8s-master ~]# kubeadm token create
获取–discovery-token-ca-cert-hash值
[root@k8s-master ~]# openssl x509 -pubkey -in /etc/kubernetes/pki/ca.crt | openssl rsa -pubin -outform der 2>/dev/null |
openssl dgst -sha256 -hex | sed ‘s/^.* //’
加入集群命令–在node节点执行
[root@k8s-master ~]# kubeadm join 192.168.1.106:6443 --token token
–discovery-token-ca-cert-hash sha256:sha256的值
注意: 需要替换两个位置的值
第一个位置替换:token
第二个位置替换:sha256的值
当遇到CouldnotfindaJWSsignatureinthecluster-infoConfigMapfortokenID和kubeadmjoin预飞阶段错误:无法验证API服务器的身份的错误时,通常是因为token无效或不存在。解决方法包括检查和重新生成token,获取discovery-token-ca-cert-hash值,并使用这些信息更新kubeadmjoin命令来加入集群。

4203

被折叠的 条评论
为什么被折叠?



