Skip to content

Commit 4a650bd

Browse files
authored
Merge pull request #98609 from cbippley/OSDOCS-15792
OSDOCS-16102 Adding oc adm upgrade recommend to updating with cli
2 parents 804f271 + ee7250d commit 4a650bd

9 files changed

+112
-227
lines changed

modules/update-conditional-updates.adoc

Lines changed: 0 additions & 27 deletions
This file was deleted.
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * updating/updating_a_cluster/updating-cluster-cli.adoc
4+
5+
:_mod-docs-content-type: CONCEPT
6+
[id="update-upgrading-oc-adm-upgrade-status_{context}"]
7+
= Cluster update status using oc adm upgrade status
8+
9+
When updating your cluster, the `oc adm upgrade` command returns limited information about the status of your update. The cluster administrator can use the `oc adm upgrade status` command to decouple status information from the `oc adm upgrade` command and return specific information regarding a cluster update, including the status of the control plane and worker node updates. Worker is also known as compute.
10+
11+
The `oc adm upgrade status` command is read-only and does not alter any state in your cluster.
12+
13+
The `oc adm upgrade status` command can be used for clusters from version 4.12 up to the latest supported release.
14+
15+
The `oc adm upgrade status` command will output three sections, control plane update, worker nodes update, and health insights.
16+
17+
* *Control Plane Update*: Displays details about the updating cluster control plane, contains a high-level assessment, completion status, duration estimate, or cluster operator health. The section also shows a table with control plane node update information.
18+
+
19+
The control plane update section can also show an additional table that lists cluster operators being updated if the `--details=operators` or `--details-all` flags are used. Please note that due the asynchronous distributed nature of {product-title}, an operator may appear in this section more than once during the update, or not at all. The section is only shown when a Cluster Operator is observed to be updating. It is normal during an update to observe no updating Cluster Operator at certain periods; not every performed action can be assigned to an observable updating Cluster Operator.
20+
+
21+
* *Worker Notes Update*: Displays the worker node update information. The worker nodes section starts with a table that displays a summary of information about each worker pool configured in the cluster. Each non-empty worker pool output will show a dedicated table listing update information about nodes that belong to that pool. If a cluster does not have any worker nodes the output will not contain the worker node section. You can make the node tables show all lines by using `--details=nodes` or `--details=all`.
22+
+
23+
* *Health Insights*: displays insights about states and events present in the cluster that may be relevant for the ongoing update. You can use `--details=health` to expand the items in this section into a more verbose form with more content such as documentation links, longer form descriptions, or cluster resources involved in the insight.
24+
25+
[NOTE]
26+
====
27+
The `oc adm upgrade status` command is currently not supported on {hcp} clusters.
28+
====
29+
30+
The following is an example of the output you will see for an update progressing successfully:
31+
32+
[source,terminal]
33+
----
34+
= Control Plane =
35+
Assessment: Progressing
36+
Target Version: 4.17.1 (from 4.17.0)
37+
Updating: machine-config
38+
Completion: 97% (32 operators updated, 1 updating, 0 waiting)
39+
Duration: 54m (Est. Time Remaining: <10m)
40+
Operator Status: 32 Healthy, 1 Unavailable
41+
42+
Control Plane Nodes
43+
NAME ASSESSMENT PHASE VERSION EST MESSAGE
44+
ip-10-0-53-40.us-east-2.compute.internal Progressing Draining 4.17.0 +10m
45+
ip-10-0-30-217.us-east-2.compute.internal Outdated Pending 4.17.0 ?
46+
ip-10-0-92-180.us-east-2.compute.internal Outdated Pending 4.17.0 ?
47+
48+
= Worker Upgrade =
49+
50+
WORKER POOL ASSESSMENT COMPLETION STATUS
51+
worker Progressing 0% (0/2) 1 Available, 1 Progressing, 1 Draining
52+
infra Progressing 50% (1/2) 1 Available, 1 Progressing, 1 Draining
53+
54+
Worker Pool Nodes: Worker
55+
NAME ASSESSMENT PHASE VERSION EST MESSAGE
56+
ip-10-0-4-159.us-east-2.compute.internal Progressing Draining 4.17.0 +10m
57+
ip-10-0-99-40.us-east-2.compute.internal Outdated Pending 4.17.0 ?
58+
59+
Worker Pool Nodes: infra
60+
NAME ASSESSMENT PHASE VERSION EST MESSAGE
61+
ip-10-0-4-159-infra.us-east-2.compute.internal Progressing Draining 4.17.0 +10m
62+
ip-10-0-20-162.us-east-2.compute.internal Completed Updated 4.17.1 -
63+
64+
= Update Health =
65+
SINCE LEVEL IMPACT MESSAGE
66+
54m4s Info None Update is proceeding well
67+
----

modules/update-upgrading-cli.adoc

Lines changed: 42 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ of the Customer Portal.
1717

1818
* Install the OpenShift CLI (`oc`) that matches the version for your updated version.
1919
* Log in to the cluster as user with `cluster-admin` privileges.
20-
2120
* Pause all `MachineHealthCheck` resources.
21+
// Example output Failing=true taken from https://github.com/openshift/oc/blob/main/pkg/cli/admin/upgrade/recommend/examples/4.16.27-degraded-monitoring.output
2222
2323
.Procedure
2424

@@ -27,47 +27,50 @@ you want to apply:
2727
+
2828
[source,terminal]
2929
----
30-
$ oc adm upgrade
30+
$ oc adm upgrade recommend
3131
----
3232
+
3333
ifndef::openshift-origin[]
3434
.Example output
3535
[source,terminal]
3636
----
37-
Cluster version is 4.13.10
38-
Upstream is unset, so the cluster will use an appropriate default.
39-
Channel: stable-4.13 (available channels: candidate-4.13, candidate-4.14, fast-4.13, stable-4.13)
40-
Recommended updates:
41-
VERSION IMAGE
42-
4.13.14 quay.io/openshift-release-dev/ocp-release@sha256:406fcc160c097f61080412afcfa7fd65284ac8741ac7ad5b480e304aba73674b
43-
4.13.13 quay.io/openshift-release-dev/ocp-release@sha256:d62495768e335c79a215ba56771ff5ae97e3cbb2bf49ed8fb3f6cefabcdc0f17
44-
4.13.12 quay.io/openshift-release-dev/ocp-release@sha256:73946971c03b43a0dc6f7b0946b26a177c2f3c9d37105441315b4e3359373a55
45-
4.13.11 quay.io/openshift-release-dev/ocp-release@sha256:e1c2377fdae1d063aaddc753b99acf25972b6997ab9a0b7e80cfef627b9ef3dd
37+
Failing=True:
38+
39+
Reason: ClusterOperatorNotAvailable
40+
Message: Cluster operator monitoring is not available
41+
...
42+
Upstream update service: https://api.integration.openshift.com/api/upgrades_info/graph
43+
Channel: candidate-4.16 (available channels: candidate-4.16, candidate-4.17, candidate-4.18, eus-4.16, fast-4.16, fast-4.17, stable-4.16, stable-4.17)
44+
45+
Updates to 4.16:
46+
VERSION ISSUES
47+
4.16.32 no known issues relevant to this cluster
48+
4.16.30 no known issues relevant to this cluster
49+
And 2 older 4.16 updates you can see with '--show-outdated-releases' or '--version VERSION'.
4650
----
4751
endif::openshift-origin[]
4852
ifdef::openshift-origin[]
4953
.Example output
5054
[source,terminal]
5155
----
52-
Cluster version is 4.13.0-0.okd-2023-10-28-065448
56+
...
5357

54-
Upstream: https://amd64.origin.releases.ci.openshift.org/graph
55-
Channel: stable-4
58+
Upstream update service: https://amd64.origin.releases.ci.openshift.org/graph
59+
Channel: stable-scos-4
5660

57-
Recommended updates:
61+
Updates to 4.20:
62+
VERSION ISSUES
63+
4.20.0-okd-scos.ec.14 no known issues relevant to this cluster
5864

59-
VERSION IMAGE
60-
4.14.0-0.okd-2024-01-06-084517 registry.ci.openshift.org/origin/release@sha256:c4a6b6850701202f629c0e451de784b02f0de079650a1b9ccbf610448ebc9227
61-
4.14.0-0.okd-2023-11-14-101924 registry.ci.openshift.org/origin/release@sha256:72d40c51e7c4d1b9c31e9b0d276d045f1b2b93def5ecee49186df856d40bcb5c
62-
4.14.0-0.okd-2023-11-12-042703 registry.ci.openshift.org/origin/release@sha256:2242d1df4e4cbcc0cd27191ab9ad5f55ac4f0c60c3cda2a186181a2435e3bd00
63-
4.14.0-0.okd-2023-10-28-073550 registry.ci.openshift.org/origin/release@sha256:7a6200e347a1b857e47f2ab0735eb1303af7d796a847d79ef9706f217cd12f5c
65+
Updates to 4.19:
66+
VERSION ISSUES
67+
4.19.0-okd-scos.17 no known issues relevant to this cluster
6468
----
6569
endif::openshift-origin[]
6670
+
6771
[NOTE]
6872
====
69-
* If there are no recommended updates, updates that have known issues might still be available.
70-
See _Updating along a conditional update path_ for more information.
73+
* You can use the `--version` flag to determine whether a specific version is recommended for your update. If there are no recommended updates, updates that have known issues might still be available.
7174
ifndef::openshift-origin[]
7275
* For details and information on how to perform a `Control Plane Only` update, please refer to the _Preparing to perform a Control Plane Only update_ page, listed in the Additional resources section.
7376
endif::openshift-origin[]
@@ -120,19 +123,32 @@ $ oc adm upgrade --to-latest=true <1>
120123
$ oc adm upgrade --to=<version> <1>
121124
----
122125
<1> `<version>` is the update version that you obtained from the output of the
123-
`oc adm upgrade` command.
126+
`oc adm upgrade recommend` command.
127+
+
128+
.. If the cluster administrator evaluates the potential known risks and decides it is acceptable for the current cluster, then the administrator can waive the safety guards and proceed with the update by running the following command:
129+
+
130+
[source,terminal]
131+
----
132+
$ oc adm upgrade --allow-not-recommended --to <version>
133+
----
124134
+
125135
[IMPORTANT]
126136
====
127137
When using `oc adm upgrade --help`, there is a listed option for `--force`. This is *heavily discouraged*, as using the `--force` option bypasses cluster-side guards, including release verification and precondition checks. Using `--force` does not guarantee a successful update. Bypassing guards put the cluster at risk.
128138
====
129139
130-
. Review the status of the Cluster Version Operator:
140+
. Optional: Review the status of the Cluster Version Operator by running the following command:
131141
+
132142
[source,terminal]
133143
----
134-
$ oc adm upgrade
144+
$ oc adm upgrade status
135145
----
146+
+
147+
[NOTE]
148+
====
149+
To monitor the update in real time, run `oc adm upgrade status` in a `watch` utility.
150+
====
151+
136152
ifdef::openshift-origin[]
137153
+
138154
[source,terminal]
@@ -196,5 +212,4 @@ ip-10-0-179-95.ec2.internal Ready worker 70m v1.33.4
196212
ip-10-0-182-134.ec2.internal Ready worker 70m v1.33.4
197213
ip-10-0-211-16.ec2.internal Ready master 82m v1.33.4
198214
ip-10-0-250-100.ec2.internal Ready worker 69m v1.33.4
199-
----
200-
215+
----

modules/update-upgrading-oc-adm-upgrade-recommend.adoc

Lines changed: 0 additions & 85 deletions
This file was deleted.

modules/update-upgrading-oc-adm-upgrade-status.adoc

Lines changed: 0 additions & 75 deletions
This file was deleted.

updating/troubleshooting_updates/gathering-data-cluster-update.adoc

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ include::modules/gathering-log-data.adoc[leveloffset=+1]
1717

1818
include::modules/changing-cvo-log-level.adoc[leveloffset=+1]
1919

20-
include::modules/update-upgrading-oc-adm-upgrade-status.adoc[leveloffset=+1]
21-
2220
include::modules/gathering-clusterversion-history.adoc[leveloffset=+1]
2321

2422
include::modules/gathering-clusterversion-history-console.adoc[leveloffset=+2]

0 commit comments

Comments
 (0)