执行命令升级
./kk upgrade --with-kubernetes v1.20.4 --with-kubesphere v3.1.0
从升级结果看kubernetes已经升级成功
+----------+------+------+---------+----------+-------+-------+-----------+---------+------------+-------------+------------------+--------------+
| name | sudo | curl | openssl | ebtables | socat | ipset | conntrack | docker | nfs client | ceph client | glusterfs client | time |
+----------+------+------+---------+----------+-------+-------+-----------+---------+------------+-------------+------------------+--------------+
| ecs-437c | y | y | y | y | y | y | y | 19.03.8 | | | | CST 23:15:39 |
+----------+------+------+---------+----------+-------+-------+-----------+---------+------------+-------------+------------------+--------------+
Warning:
An old Docker version may cause the failure of upgrade. It is recommended that you upgrade Docker to 20.10+ beforehand.
Issue: https://github.com/kubernetes/kubernetes/issues/101056
Cluster nodes status:
NAME STATUS ROLES AGE VERSION
ecs-437c NotReady control-plane,master,worker 24d v1.20.4
Upgrade Confirmation:
kubernetes version: v1.20.4 to v1.20.4
kubesphere version: v3.0.0 to v3.1.0
Continue upgrading cluster? [yes/no]: yes
INFO[23:16:02 CST] Get current version
INFO[23:16:02 CST] Configuring operating system ...
[ecs-437c 192.168.0.139] MSG:
vm.swappiness = 1
net.core.somaxconn = 1024
net.ipv4.tcp_max_tw_buckets = 5000
net.ipv4.tcp_max_syn_backlog = 1024
net.ipv4.ip_forward = 1
net.bridge.bridge-nf-call-arptables = 1
net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
net.ipv4.ip_local_reserved_ports = 30000-32767
vm.max_map_count = 262144
fs.inotify.max_user_instances = 524288
INFO[23:16:04 CST] Upgrading kube cluster
INFO[23:16:04 CST] Deploying KubeSphere ...
v3.1.0
[ecs-437c 192.168.0.139] MSG:
namespace/kubesphere-system unchanged
namespace/kubesphere-monitoring-system unchanged
[ecs-437c 192.168.0.139] MSG:
namespace/kubesphere-system unchanged
serviceaccount/ks-installer unchanged
Warning: apiextensions.k8s.io/v1beta1 CustomResourceDefinition is deprecated in v1.16+, unavailable in v1.22+; use apiextensions.k8s.io/v1 CustomResourceDefinition
customresourcedefinition.apiextensions.k8s.io/clusterconfigurations.installer.kubesphere.io unchanged
clusterrole.rbac.authorization.k8s.io/ks-installer unchanged
clusterrolebinding.rbac.authorization.k8s.io/ks-installer unchanged
deployment.apps/ks-installer configured
Please wait for the installation to complete: <---<<
然后就一直等待,直到失败。
