kuberadm集群升级
升级kubernetes集群
注意不能跨版本升级
比如1.13.x 要先升级到1.14.x,不能直接升级到1.15.x
举例说明升级到1.15,和1.14有些参数不一样,具体看官网:
https://kubernetes.io/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade-1-14/
https://kubernetes.io/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade-1-15/
升级步骤
升级kuberadm
yum install -y cri-tools-1.12.0-0.x86_64.rpm kubeadm-1.15.0-0.x86_64.rpm kubectl-1.15.0-0.x86_64.rpm kubelet-1.15.0-0.x86_64.rpm kubernetes-cni-0.7.5-0.x86_64.rpm
升级控制节点
kubeadm upgrade plan kubeadm upgrade apply v1.15.0 systemctl daemon-reload systemctl restart kubelet
升级工作节点
kubeadm upgrade node #这里和升级1.14不一样,kubeadm upgrade node config --kubelet-version v1.14.3 systemctl daemon-reload systemctl restart kubelet