From 4e5ba95b6c073f1b27acd9ed319c0349cb439339 Mon Sep 17 00:00:00 2001 From: haasad Date: Thu, 7 Sep 2023 14:33:26 +0200 Subject: [PATCH 1/3] Remove manual maintenance procdure, convert troubleshooting to own page Relates: OCP-850 --- ....adoc => maintenance_troubleshooting.adoc} | 108 +----------------- docs/modules/ROOT/partials/nav.adoc | 2 +- 2 files changed, 2 insertions(+), 108 deletions(-) rename docs/modules/ROOT/pages/how-tos/{update_maintenance.adoc => maintenance_troubleshooting.adoc} (63%) diff --git a/docs/modules/ROOT/pages/how-tos/update_maintenance.adoc b/docs/modules/ROOT/pages/how-tos/maintenance_troubleshooting.adoc similarity index 63% rename from docs/modules/ROOT/pages/how-tos/update_maintenance.adoc rename to docs/modules/ROOT/pages/how-tos/maintenance_troubleshooting.adoc index 92f623ab..fcaed9f7 100644 --- a/docs/modules/ROOT/pages/how-tos/update_maintenance.adoc +++ b/docs/modules/ROOT/pages/how-tos/maintenance_troubleshooting.adoc @@ -1,110 +1,4 @@ -= Maintenance and Update of an OpenShift 4 cluster - -In contrast to previous versions of OpenShift, or other Kubernetes distributions, the operating system (https://docs.openshift.com/container-platform/4.11/architecture/architecture-rhcos.html[Red Hat Enterprise Linux CoreOS (RHCOS)]) and OCP4 server components are bundled into a single unit. -In practice, this means that there is no difference between "updating the operating system" or "installing the latest OCP version," it's all the same. - -[IMPORTANT] -==== -For an upgrade to `4.12`, see xref:oc4:ROOT:how-tos/update_maintenance/v_4_12.adoc[Upgrade to OpenShift 4.12] first. -==== - -. Get list of available updates: -+ -[source,console] ----- -oc adm upgrade --as cluster-admin - -Updates: - -VERSION IMAGE -4.5.19 quay.io/openshift-release-dev/ocp-release@sha256:bae5510f19324d8e9c313aaba767e93c3a311902f5358fe2569e380544d9113e -4.5.20 quay.io/openshift-release-dev/ocp-release@sha256:78b878986d2d0af6037d637aa63e7b6f80fc8f17d0f0d5b077ac6aca83f792a0 -4.5.24 quay.io/openshift-release-dev/ocp-release@sha256:f3ce0aeebb116bbc7d8982cc347ffc68151c92598dfb0cc45aaf3ce03bb09d11 ----- - -or - -[source,console] ----- -kubectl --as cluster-admin get clusterversion version -o json | jq '.status.availableUpdates[] | {image: .image, version: .version}' ----- - -[NOTE] -==== -If you don't get the newest available version, this might be intended. -Red Hat does release new updates to specific cluster, when they do have no known issues. -So on a stable channel you need some patience! -==== - -. Update the configuration hierarchy -+ -Set the following parameters to the values retrieved in the previous step: -+ -* `parameters.openshift4_version.spec.desiredUpdate.image` -* `parameters.openshift4_version.spec.desiredUpdate.version` - -. Compile the cluster catalog - -. Enjoy the show -+ -Let the OpenShift operators do their job. -+ -[source,console] ----- -kubectl --as cluster-admin get clusterversion version --watch ----- -+ -. Check the upgrade state via the `oc` command: -+ -[source,console] ----- -$ oc adm upgrade --as cluster-admin -Cluster version is 4.5.24 - -No updates available. -You may force an upgrade to a specific release image, but doing so may not be supported and result in downtime or data loss. ----- -+ -NOTE: Even if `oc adm upgrade` shows that the upgrade has completed, it's possible that nodes are still being upgraded. - -. Check node upgrade status by checking the status of the `MachineConfigPool` resources: -+ -[source,console] ----- -$ oc --as=cluster-admin -n openshift-machine-config-operator get machineconfigpool -NAME CONFIG UPDATED UPDATING DEGRADED MACHINECOUNT READYMACHINECOUNT UPDATEDMACHINECOUNT DEGRADEDMACHINECOUNT AGE -master rendered-master-92e100dc64d7c9ecf669b1f69cdb5dca True False False 3 3 3 0 19d -worker rendered-worker-4648c4badfb057c7e3e9f1030fa42507 True False False 6 6 6 0 19d ----- -+ -[IMPORTANT] -==== -Applications on the cluster may get rescheduled without prior notice as long as the worker `MachineConfigPool` doesn't show `Updated=True`. - -You can observe the progress of the node upgrades with - -[source,console] ----- -oc --as=cluster-admin get mcp -w ----- -==== - -. The maintenance of the cluster is only finished once all nodes, including all worker nodes have been upgraded and all `MachineConfigPools` show `Updated=True`. -+ -[IMPORTANT] -==== -Never leave the cluster in a state with pending node upgrades. -If the Machine Config operator can't drain a node (for example because doing so would violate a `PodDisruptionBudget`) you may have to manually force-drain a node or even manually delete pods that block the node drain. -Always open a follow-up ticket to investigate the underlying issues if manual intervention is required. -==== - -So far, the upgrade process mostly just worked. -Nevertheless, we've started documenting how to observe the upgrade process in the following section. -More troubleshooting instructions will be added there as we gain experience. - -For general information about the upgrade process, check out https://docs.openshift.com/container-platform/latest/updating/updating-cluster-between-minor.html[Updating a cluster between minor versions] of the OpenShift 4 documentation. - -Also have a look at the blog post https://www.openshift.com/blog/the-ultimate-guide-to-openshift-release-and-upgrade-process-for-cluster-administrators[The Ultimate Guide to OpenShift Release and Upgrade Process for Cluster Administrators] which is an excellent source to understand the process. += Maintenance troubleshooting == Troubleshooting diff --git a/docs/modules/ROOT/partials/nav.adoc b/docs/modules/ROOT/partials/nav.adoc index 36e04ebb..421c1e32 100644 --- a/docs/modules/ROOT/partials/nav.adoc +++ b/docs/modules/ROOT/partials/nav.adoc @@ -81,12 +81,12 @@ *** xref:oc4:ROOT:how-tos/vsphere/install.adoc[Install] * Update -** xref:oc4:ROOT:how-tos/update_maintenance.adoc[Update/Maintenance] ** xref:oc4:ROOT:how-tos/update_maintenance/automated-upgrades-at-vshn.adoc[] ** xref:oc4:ROOT:how-tos/new_minor.adoc[Get ready for new minor] ** xref:oc4:ROOT:how-tos/update_maintenance/v_4_12.adoc[Upgrade to OCP4.12] ** xref:oc4:ROOT:how-tos/update_maintenance/v_4_13.adoc[Upgrade to OCP4.13] ** xref:oc4:ROOT:references/architecture/upgrade_controller.adoc[Upgrade Controller] +** xref:oc4:ROOT:how-tos/maintenance_troubleshooting.adoc[Maintenance troubleshooting] // Support // Web console From bedaec6a1ad1a3ba1fc5aabced80d842ca08770e Mon Sep 17 00:00:00 2001 From: haasad Date: Thu, 7 Sep 2023 15:07:19 +0200 Subject: [PATCH 2/3] Update instructions for 4.12 and 4.13 minor upgrades --- docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_12.adoc | 2 +- docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_13.adoc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_12.adoc b/docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_12.adoc index 77dea069..0b5c4ac7 100644 --- a/docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_12.adoc +++ b/docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_12.adoc @@ -86,4 +86,4 @@ kubectl patch cm admin-acks \ . Upgrade the cluster + -Follow the steps in xref:oc4:ROOT:how-tos/update_maintenance.adoc[Update/Maintenance]. +Set the desired minor version in https://github.com/appuio/component-openshift-upgrade-controller/blob/master/docs/modules/ROOT/pages/references/parameters.adoc#cluster_versionopenshiftversion[`openshift_upgrade_controller.cluster_version.openshiftVersion.Minor`]. The ugprade controller will use this upgrade channel in the next maintenance window. diff --git a/docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_13.adoc b/docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_13.adoc index 2b4a54b2..7235e404 100644 --- a/docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_13.adoc +++ b/docs/modules/ROOT/pages/how-tos/update_maintenance/v_4_13.adoc @@ -85,4 +85,4 @@ kubectl patch cm admin-acks \ . Upgrade the cluster + -Follow the steps in xref:oc4:ROOT:how-tos/update_maintenance.adoc[Update/Maintenance]. +Set the desired minor version in https://github.com/appuio/component-openshift-upgrade-controller/blob/master/docs/modules/ROOT/pages/references/parameters.adoc#cluster_versionopenshiftversion[`openshift_upgrade_controller.cluster_version.openshiftVersion.Minor`]. The ugprade controller will use this upgrade channel in the next maintenance window. From 486bb643509736d4d390a4e9cb57702b1ca5a756 Mon Sep 17 00:00:00 2001 From: haasad Date: Thu, 7 Sep 2023 15:09:23 +0200 Subject: [PATCH 3/3] Update navigation link for day two operations --- docs/modules/ROOT/partials/nav.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/modules/ROOT/partials/nav.adoc b/docs/modules/ROOT/partials/nav.adoc index 421c1e32..50cb22df 100644 --- a/docs/modules/ROOT/partials/nav.adoc +++ b/docs/modules/ROOT/partials/nav.adoc @@ -175,7 +175,7 @@ // Serverless * Day two operations -** xref:oc4:ROOT:how-tos/update_maintenance.adoc[Update/Maintenance] +** xref:oc4:ROOT:how-tos/maintenance_troubleshooting.adoc[Maintenance troubleshooting] ** xref:oc4:ROOT:how-tos/debug-nodes.adoc[Debugging Nodes] ** Runbooks