etcdctl 恢复k8s后报错

复制代码
Error from server (Forbidden): replicationcontrollers is forbidden: User "system:node:192.168.1.107" cannot list resource "replicationcontrollers" in API group "" in the namespace "harbor"
Error from server (Forbidden): daemonsets.apps is forbidden: User "system:node:192.168.1.107" cannot list resource "daemonsets" in API group "apps" in the namespace "harbor"
Error from server (Forbidden): deployments.apps is forbidden: User "system:node:192.168.1.107" cannot list resource "deployments" in API group "apps" in the namespace "harbor"
Error from server (Forbidden): replicasets.apps is forbidden: User "system:node:192.168.1.107" cannot list resource "replicasets" in API group "apps" in the namespace "harbor"
Error from server (Forbidden): statefulsets.apps is forbidden: User "system:node:192.168.1.107" cannot list resource "statefulsets" in API group "apps" in the namespace "harbor"
Error from server (Forbidden): horizontalpodautoscalers.autoscaling is forbidden: User "system:node:192.168.1.107" cannot list resource "horizontalpodautoscalers" in API group "autoscaling" in the namespace "harbor"
Error from server (Forbidden): cronjobs.batch is forbidden: User "system:node:192.168.1.107" cannot list resource "cronjobs" in API group "batch" in the namespace "harbor"
Error from server (Forbidden): jobs.batch is forbidden: User "system:node:192.168.1.107" cannot list resource "jobs" in API group "batch" in the namespace "harbor"

提示该master节点无权限,应该是在恢复的时候操作不当

在备用master节点上加上

复制代码
kubectl create clusterrolebinding system:node:192.168.1.107   --clusterrole=cluster-admin   --user=system:node:192.168.1.107
相关推荐
逍遥浪子~11 分钟前
docker实践(一)
运维·docker·容器
AI云原生1 小时前
如何使用Docker快速运行Firefox并实现远程访问本地火狐浏览器的教程
运维·docker·云原生·容器·serverless·firefox·kubeless
❀͜͡傀儡师3 小时前
Docker部署搜索引擎SearXNG
运维·docker·容器·searxng
泡沫冰@3 小时前
K8S集群管理(3)
云原生·容器·kubernetes
麦兜*3 小时前
MongoDB 常见错误解决方案:从连接失败到主从同步问题
java·数据库·spring boot·redis·mongodb·容器
LQ深蹲不写BUG5 小时前
微服务事务管理利器:Seata 核心原理与实践指南
微服务·云原生·架构
nathan05296 小时前
Kubernetes 实战练习指南
云原生·容器·kubernetes
無名之輩6 小时前
Nvidia Device Plugin入门二之envvar策略
kubernetes
云和数据.ChenGuang8 小时前
微服务技术栈
微服务·云原生·架构
syty20208 小时前
K8s是什么
容器·kubernetes·dubbo