From 740b4fb4152fb50cb216a42f16360bc07128f9e8 Mon Sep 17 00:00:00 2001 From: Jason DeTiberus Date: Tue, 27 Nov 2018 15:49:58 -0500 Subject: [PATCH] Update stacked controlplane steps --- .../kubeadm/kubeadm-upgrade-ha-1-13.md | 84 +++---------------- 1 file changed, 10 insertions(+), 74 deletions(-) diff --git a/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade-ha-1-13.md b/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade-ha-1-13.md index 76a9c564699da..8b019ea043889 100644 --- a/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade-ha-1-13.md +++ b/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade-ha-1-13.md @@ -66,42 +66,20 @@ CoreDNS 1.2.2 1.2.6 Modify `configmap/kubeadm-config` for this control plane node: ```shell -kubectl get configmap -n kube-system kubeadm-config -o yaml > kubeadm-config-cm.yaml +kubectl edit configmap -n kube-system kubeadm-config ``` -Open the file in an editor and replace the following values: +Make the following modifications to the ClusterConfiguration key: -- `api.advertiseAddress` +- `etcd` - This should be set to the local node's IP address. + Remove the etcd section completely -- `etcd.local.extraArgs.advertise-client-urls` +Make the following modifications to the ClusterStatus key: - This should be updated to the local node's IP address. +- `apiEndpoints` -- `etcd.local.extraArgs.initial-advertise-peer-urls` - - This should be updated to the local node's IP address. - -- `etcd.local.extraArgs.listen-client-urls` - - This should be updated to the local node's IP address. - -- `etcd.local.extraArgs.listen-peer-urls` - - This should be updated to the local node's IP address. - -- `etcd.local.extraArgs.initial-cluster` - - This should be updated to include the hostname and IP address pairs for each control plane node in the cluster. For example: - - "ip-172-31-92-42=https://172.31.92.42:2380,ip-172-31-89-186=https://172.31.89.186:2380,ip-172-31-90-42=https://172.31.90.42:2380" - -You must also pass an additional argument (`initial-cluster-state: existing`) to etcd.local.extraArgs. - -```shell -kubectl apply -f kubeadm-config-cm.yaml --force -``` + Add an entry for each of the additional control plane hosts Start the upgrade: @@ -111,60 +89,18 @@ kubeadm upgrade apply v You should see something like the following: - [upgrade/successful] SUCCESS! Your cluster was upgraded to "v1.12.0". Enjoy! + [upgrade/successful] SUCCESS! Your cluster was upgraded to "v1.13.0". Enjoy! -The `kubeadm-config` ConfigMap is now updated from `v1alpha2` version to `v1alpha3`. +The `kubeadm-config` ConfigMap is now updated from `v1alpha3` version to `v1beta1`. ### Upgrading additional control plane nodes -Each additional control plane node requires modifications that are different from the first control plane node. Run: - -```shell -kubectl get configmap -n kube-system kubeadm-config -o yaml > kubeadm-config-cm.yaml -``` - -Open the file in an editor and replace the following values for `ClusterConfiguration`: - -- `etcd.local.extraArgs.advertise-client-urls` - - This should be updated to the local node's IP address. - -- `etcd.local.extraArgs.initial-advertise-peer-urls` - - This should be updated to the local node's IP address. - -- `etcd.local.extraArgs.listen-client-urls` - - This should be updated to the local node's IP address. - -- `etcd.local.extraArgs.listen-peer-urls` - - This should be updated to the local node's IP address. - -You must also modify the `ClusterStatus` to add a mapping for the current host under apiEndpoints. - -Add an annotation for the cri-socket to the current node, for example to use docker: - -```shell -kubectl annotate node kubeadm.alpha.kubernetes.io/cri-socket=/var/run/dockershim.sock -``` - -Apply the modified kubeadm-config on the node: - -```shell -kubectl apply -f kubeadm-config-cm.yaml --force -``` - Start the upgrade: ```shell -kubeadm upgrade apply v +kubeadm upgrade node experimental-control-plane ``` -You should see something like the following: - - [upgrade/successful] SUCCESS! Your cluster was upgraded to "v1.12.0". Enjoy! - ## External etcd ### Upgrade the first control plane