What is the recommended way to upgrade the kubernetes cluster when releasing new versions?

What is the recommended way to upgrade the kubernetes cluster when releasing new versions?

I heard here , it could be https://github.com/kubernetes/kubernetes/blob/master/cluster/kube-push.sh . If so, how does kube-push.sh refer to https://github.com/GoogleCloudPlatform/kubernetes/blob/master/cluster/gce/upgrade.sh ?

I also heard here that instead we should create a new cluster, copy / move containers, replication controllers and services from the first cluster to a new one, and then turn off the first cluster.

I am running my cluster on aws if that matters.

+7
kubernetes
source share
1 answer

The second script link (gce / upgrade.sh) only works if your cluster is running GCE. There is no (equivalent) script for AWS, but you can look at the script and follow the steps (or write them to the script) to get the same behavior.

The main differences between upgrade.sh and kube-push.sh are that the first one performs an upgrade to replace (remove the node, create a new node to replace it), while the later one does the "in-place" upgrade.

Removing and replacing a node wizard only works if persistent data (etcd database, server certificates, authorized bearer tokens, etc.) are located on a permanent disk separately from the master’s boot disk (this is the default setting in GCE) . Removing and replacing nodes should be OK on AWS (but keep in mind that any modules not under the replication controller will not be restarted).

Performing an in-place upgrade does not require any special configuration, but this code path is not as thoroughly tested as the uninstall and replace option.

You do not need to completely replace your cluster when upgrading to a new version, unless you are using pre-release versions (e.g. alpha or beta), which can sometimes have interruptions between them.

+8
source share

All Articles