Kubernetes 在 3 节点 HA 集群上失去了控制平面。

huangapple go评论62阅读模式
英文:

Kubernetes lost control plane on 3 node HA cluster

问题

我有一个具有3个高可用节点的Kubernetes集群,分布在3台不同的服务器上。其中一台服务器上有控制平面,并且已被删除(意味着我丢失了该服务器)。

现在,另外两台服务器正常运行,所有部署和服务都在运行,但我无法访问该集群。

如何恢复这种情况?

感谢您的帮助。

英文:

I have a Kubernetes cluster with 3 HA nodes on 3 different servers. One of the server had the control plane and got deleted (meaning, I lost the server).

Right now, other two servers are running normally and all deployments and services are running, however I don't have any access to the cluster.

How can I recover this scenario?

Thanks for your help.

答案1

得分: 1

以下是已翻译的内容:

  • 如果您没有对实例进行快照和备份ETCD数据,请注意,如果您要恢复丢失的控制平面节点,那么请按照此**博客**中提到的步骤进行操作。
  • 检查控制平面是否处于Not Ready状态,并检查节点上是否已安装etcd客户端,如果没有,请安装。
  • 现在,在检查etcd成员状态后,从另外两个节点中删除与已删除控制平面相关联的etcd成员。
  • 现在,使用现有快照创建新节点,否则创建新实例并安装Kubernetes控制平面组件。
  • 使用生成的新令牌将节点加入新的控制平面节点。

请查看上述博客以获取有关安装etcd客户端和其他命令的更多信息。

英文:

Restoring a lost control plane node is very troublesome if you haven’t taken snapshots of the instance and the backup of ETCD data, then follow these steps as mentioned in this blog.

  • Check whether the control plane is in Not Ready state and check
    whether you have the etcd client installed in the nodes, else
    install it.
  • Now remove the etcd member which is associated with the deleted
    control plane from the other two nodes after checking the etcd
    member status.
  • Now create a new node using the existing snapshot else create a new
    instance and install kubernetes control plane components.
  • Join the nodes to the new control plane node using the new token
    generated.

Follow the above blog for more information on instructions related to installing etcd client and other commands.

huangapple
  • 本文由 发表于 2023年6月26日 16:25:30
  • 转载请务必保留本文链接:https://go.coder-hub.com/76554866.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定