当前版本:

kubectl version


最新版本:

kubeadm upgrade plan

客户端版本:

/usr/bin/yum makecache fast
rpm -qa |grep kube


卸载老的:

yum remove -y \
kubectl-1.22.1-0.x86_64 \
kubernetes-cni-0.8.7-0.x86_64   \
kubelet-1.22.1-0.x86_64 \
kubeadm-1.22.1-0.x86_64 

安装客户端:

yum install -y \
kubectl  \
kubernetes-cni   \
kubelet  \
kubeadm  

最新版本:

rpm -qa |grep kube

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

docker pull registry.aliyuncs.com/google_containers/kube-apiserver:v1.22.3
docker pull registry.aliyuncs.com/google_containers/kube-controller-manager:v1.22.3
docker pull registry.aliyuncs.com/google_containers/kube-scheduler:v1.22.3
docker pull registry.aliyuncs.com/google_containers/kube-proxy:v1.22.3
docker pull registry.aliyuncs.com/google_containers/etcd:3.5.0-0
docker pull registry.aliyuncs.com/google_containers/coredns:1.8.4
docker tag  registry.aliyuncs.com/google_containers/coredns:1.8.4 registry.aliyuncs.com/google_containers/coredns:v1.8.4

升级:

kubeadm upgrade apply v1.22.3

重启:

systemctl daemon-reload
service kubelet restart
kubectl get nodes


当前版本:

kubectl version

发表评论

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

Captcha Code