声明:本文乃“运维家”原创,转载请注明出处,更多内容请关注公众号“运维家”。

主旨
上一节中我们说了k8s的核心概念,这节我们介绍下k8s的架构设计是怎样的,只有了解了架构设计,我们才能更好的进行规划部署,以及更好的理解整体流程。
服务器
master
worker
可以分为master和worker两种角色,master是管理worker的,如下图:

存储
我们知道,存储是非常重要的,如果不持久化的话,一旦整体集群出现什么异常,数据丢失了,那就不是那么美好了,k8s中存储方式采用的是etcd数据库集群的方式。

ApiServer
部署在master节点上,用来对外提供服务,比如http或者https访问,是操作k8s的唯一入口。比如新创建服务,该是个啥流程呢,往下看。

Scheduler
Scheduler:调度器,也部署在了master节点上,当apiserver接受到了创建服务的请求,首先需要确定调度到哪个worker节点上,这个时候apiserver就会去请求Scheduler来确定,因为scheduler会统计每台worker节点上的服务器性能,以此来确定最优的选择,并将节点和pod之间的关系,反馈给apiserver,然后apiserver将信息存储在ETCD数据库中。

Controllermanager
剩余内容请关注微信公众号 “运维家” ,回复 “110” 查看。
网友评论