I’d like to upgrade our Kubernetes Clusters from version 1.27.x to 1.30.x using kubeadm.
Is is possible to do the upgrade in one step or do I really need to upgrade from 1.27 to 1.28, 1.28 to 1.29 and 1.29 to 1.30?
When I try to upgrade to v1.30.3 directly, I get the following error –
# kubeadm upgrade apply v1.30.3
[preflight] Running pre-flight checks.
[upgrade/config] Reading configuration from the cluster...
[upgrade/config] FYI: You can look at this config file with 'kubectl -n kube-system get cm kubeadm-config -o yaml'
[upgrade] Running cluster health checks
[upgrade/version] You have chosen to change the cluster version to "v1.30.3"
[upgrade/versions] Cluster version: v1.27.1
[upgrade/versions] kubeadm version: v1.30.3
[upgrade/version] FATAL: the --version argument is invalid due to these fatal errors:
- Specified version to upgrade to "v1.30.3" is too high; kubeadm can upgrade only 1 minor version at a time
Please fix the misalignments highlighted above and try upgrading again
To see the stack trace of this error execute with --v=5 or higher
What is the best way going forward? I’d like to avoid doing multiple upgrade causing multiple production cluster outages. Thanks!