Kubernetes学习指南:保姆级实操手册03——规划部署
一、部署节点规划
Hostname | ip | roles |
---|---|---|
k8s-master01 | 10.255.210.1 | master |
k8s-master02 | 10.255.210.2 | master |
k8s-master03 | 10.255.210.3 | master |
k8s-node01 | 10.255.210.4 | worker node |
k8s-node02 | 10.255.210.5 | worker node |
k8s-node03 | 10.255.210.6 | worker node |
apiserver.fq.com | 10.255.210.99 | 负载均衡VIP |
serviceSubnet | 10.96.0.0/12 | service网段 |
podSubnet | 10.100.0.0/16 | pod网段 |
管理节点(master)运行服务:etcd、kube-apiserver、kube-scheduler、kube-controller-manager、docker、kubelet、keepalived、haproxy
工作节点(worker node)运行服务:docker、kubelet、kube-proxy 扩展阅读:[[k8s master节点和worker 主要运行的软件]]
二、架构说明
kubernetes 架构图
三、版本信息
软件版本
# 操作系统版本:
$ hostnamectlStatic hostname: k8s-master01Icon name: computer-vmChassis: vmMachine ID: 7be69544cd044123946847****992266Boot ID: 455261e9b8f64d378c94******efaf4Virtualization: vmwareOperating System: CentOS Linux 7 (Core)CPE OS Name: cpe:/o:centos:centos:7Kernel: Linux 6.6.9-1.el7.elrepo.x86_64Architecture: x86-64
$ cat /etc/redhat-release
CentOS Linux release 7.6.1810 (Core)# docker版本: 26.1.0
$ docker versiondocker version
Client: Docker Engine - CommunityVersion: 26.1.0API version: 1.43 (downgraded from 1.45)Go version: go1.21.9Git commit: 9714adcBuilt: Mon Apr 22 17:09:57 2024OS/Arch: linux/amd64Context: defaultServer: Docker Engine - CommunityEngine:Version: 24.0.9API version: 1.43 (minimum version 1.12)Go version: go1.20.13Git commit: fca702dBuilt: Thu Feb 1 00:50:53 2024OS/Arch: linux/amd64Experimental: falsecontainerd:Version: 1.6.31GitCommit: e377cd56a71523140ca6ae87e30244719194a521runc:Version: 1.1.12GitCommit: v1.1.12-0-g51d5e94docker-init:Version: 0.19.0GitCommit: de40ad0# cri-dockerd版本: 0.3.13
$ cri-dockerd --version
cri-dockerd 0.3.13 (5aee623)# kubeadm版本: v1.28.2
$ kubeadm version
kubeadm version: &version.Info{Major:"1", Minor:"28", GitVersion:"v1.28.2", GitCommit:"89a4ea3e1e4ddd7f7572286090359983e0387b2f", GitTreeState:"clean", BuildDate:"2023-09-13T09:34:32Z", GoVersion:"go1.20.8", Compiler:"gc", Platform:"linux/amd64"}# kubernetes版本: v1.28.0
$ kubectl get node
NAME STATUS ROLES AGE VERSION
k8s-master01 Ready control-plane 64d v1.28.2
k8s-master02 Ready control-plane 64d v1.28.2
k8s-master03 Ready control-plane 64d v1.28.2
k8s-node01 Ready <none> 64d v1.28.2
k8s-node02 Ready <none> 64d v1.28.2
k8s-node03 Ready <none> 64d v1.28.2