Kubernetes 因令牌过期新增节点报错问题处理

庆云2年前技术文章1365

1、背景

Kubernetes 集群初始化完成之后,间隔一天发现 Worker 节点无法正常加入集群。


2、报错信息

$ kubeadm join api.k8s.com:9443 --token mmvhoe.yxnfs1jzmp3i058s --discovery-token-ca-cert-hash sha256:630a00c0ea19cf578ed8d0d6444b015b516e4e203982a6bc359e76c75b2e6e8

error execution phase preflight: couldn't validate the identity of the API Server: could not find a JWS signature in the cluster-info ConfigMap for token ID "mmvhoe"
To see the stack trace of this error execute with --v=5 or higher


3、报错解决

这个错误是 Worker  节点在加入集群时无法验证 API Server 的身份导致的,根本原因是由于令牌过期导致。

# 生成令牌
$ kubeadm token create --ttl 24h
x8hadg.85bibbsp8hsyolwx

# 加入集群
$ kubeadm join api.k8s.com:9443 --token x8hadg.85bibbsp8hsyolwx --discovery-token-ca-cert-hash sha256:630a00c0ea19cf578ed8d0d6444b015b516e4e203982a6bc359e76c75b2e6e8



相关文章

Keepalived 高可用解决方案

Keepalived 高可用解决方案

Keepalived 起初是为 LVS 设计的,专门用来监控集群系统中各个服务节点的状态,后来有加入 VRRP 的功能,VRRP 是 Virtual Router Redundancy protoco...

Zabbix监控接入

Zabbix监控1、环境实验机器:118.31.158.83(zabbix server)172.17.6.11(zabbix proxy)172.17.6.11(zabbix agent)2、安装z...

MySQL运维实战(4.9) SQL_MODE之NO_UNSIGNED_SUBTRACTION

在mysql数据库中,unsigned表示不存负数,如果unsigned类型的字段作运算,得到的结果为负数,SQL会报错。mysql> create table t...

副本集的管理(二)

五、用户管理MongoDB默认是不开启用户认证模式的,但是为了数据库的安全和管理,我们需要开启用户认证。数据库用户角色:read、readWrite; 数据库管理角色:dbAdmin、dbOwner...

helm简介

helm简介

一、Helm 是什么在没使用 helm 之前,向 kubernetes 部署应用,我们要依次部署 deployment、svc 等,步骤较繁琐。况且随着很多项目微服务化,复杂的应用在容器中部署以及管理...

阿里云配置 keepalived

1 安装 keepalivedyum install keepalivedmv /etc/keepalived/keepalived.conf /etc/keepalived/keepalived.c...

发表评论    

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。