简体   繁体   English

有理由自动缩放kubernetes master吗?

[英]Is there a reason to auto-scale kubernetes master?

I am running a Kubernetes cluster with 3 master and 3 nodes. 我正在运行具有3个主节点和3个节点的Kubernetes集群。

I have found this to auto-scale worker nodes based on the pod's status. 我发现它可以根据容器的状态自动缩放工作节点。 https://github.com/kubernetes/autoscaler/tree/master/cluster-autoscaler/cloudprovider/aws https://github.com/kubernetes/autoscaler/tree/master/cluster-autoscaler/cloudprovider/aws

But, I couldn't find any blog or add-on to auto-scale master nodes. 但是,我找不到用于自动缩放主节点的任何博客或附加组件。

Is there any reason to auto-scale master nodes, if yes how can we do that? 有没有理由自动缩放主节点,如果可以,我们该怎么做?

There is no need to autoscale the master nodes. 无需autoscale主节点。 In a practical world, your worker nodes responsibility is to run your work load and your master nodes responsibility is to make sure that your worker nodes are having desired state in the cluster. 在现实世界中,工作节点的职责是运行工作负载,而主节点的职责是确保工作节点在集群中处于所需状态。

Now all the end users will request your application (pods) and as the load increased they need to scale horizontally and more pods should be spawned. 现在,所有最终用户都将请求您的应用程序(容器),并且随着负载的增加,他们需要水平扩展,并应产生更多的容器。 If the resources on worker nodes are insufficient to run those nodes, more worker nodes should be spawned. 如果辅助节点上的资源不足以运行这些节点,则应产生更多的辅助节点。

In large cluster we do not run load on master node, but we need to make sure it is highly available so that there is no single point of failure to orchestrate the worker nodes. 在大型集群中,我们不会在主节点上运行负载,但是我们需要确保它具有高可用性,以确保编排工作节点不会出现单点故障。 For that we can have 3 master multi-master cluster in place. 为此,我们可以拥有3个主多主机集群。

Worker nodes we worry about the horizontal scalability and In master node we worry about high availability . 工作节点我们担心horizontal scalability而在主节点中我们担心high availability

But for building large cluster, you need to provide adequate resources to master nodes for handling the orchestration of load on worker nodes. 但是,对于构建大型集群,您需要提供足够的资源来控制主节点,以处理工作节点上的负载编排。

For more information on building large cluster, please refer official document: 有关构建大型集群的更多信息,请参考官方文档:

https://kubernetes.io/docs/setup/cluster-large/ https://kubernetes.io/docs/setup/cluster-large/

In a nutshell, You can even have one master for 1000 worker nodes if you provide enough resources to that node. 简而言之,如果您为一个节点提供了足够的资源,那么您甚至可以为1000个工作节点拥有一个主节点。 So, there is no reason to autoscale master comparing to the challenges we face in doing so. 因此,与我们面临的挑战相比,没有理由自动缩放母版。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM