yum install -y kubeadm-1.21.4-0.x86_64 kubelet-1.21.4-0.x86_64 kubectl-1.21.4-0.x86_64

kubeadm upgrade plan

拉取镜像,注意coredns的镜像需要tag一下

docker pull registry.aliyuncs.com/google_containers/kube-apiserver:v1.21.4
docker pull registry.aliyuncs.com/google_containers/kube-controller-manager:v1.21.4
docker pull registry.aliyuncs.com/google_containers/kube-scheduler:v1.21.4
docker pull registry.aliyuncs.com/google_containers/kube-proxy:v1.21.4
docker pull registry.aliyuncs.com/google_containers/coredns:1.8.0
docker tag  registry.aliyuncs.com/google_containers/coredns:1.8.0 registry.aliyuncs.com/google_containers/coredns:v1.8.0

kubeadm upgrade apply v1.21.4


等待几分钟:

systemctl daemon-reload
service kubelet restart
kubectl get nodes

kubectl version

发表评论

您的电子邮箱地址不会被公开。 必填项已用*标注

Captcha Code