Ubuntu22.04 安装kubernetes V1.28

背景

eks用的v1.28 需要安装一致的环境

部署

服务器初始化

root@cfc:~# systemctl stop ufw
root@cfc:~# systemctl disable --now  ufw
Synchronizing state of ufw.service with SysV service script with /                                                                      lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install disable ufw
Removed /etc/systemd/system/multi-user.target.wants/ufw.service.

#修改hosts文件
root@master:~# cat /etc/hosts
10.10.10.21 node-01
10.10.10.22 node-02
10.10.10.23 node-03
192.168.200.18 k8s-node2
#时间同步
timedatectl set-timezone Asia/Shanghai
ntpdate time.windows.com


# 关闭swap内存
root@master:~# swapoff -a
root@master:~# sed -i '/swap/s/^/#/' /etc/fstab
#打开ipv4转发

你可能感兴趣的:(Kubernetes,K8S)