OpenShift - oc get clusterversion command

by
Jeremy Canfield |
Updated: November 08 2022
| OpenShift articles
If you are not familiar with the oc command, refer to OpenShift - Getting Started with the oc command.
Before issuing the oc version command, issue the oc login command. The oc get clusterversion command can be used to return the cluster version of OpenShift.
~]$ oc get clusterversion
NAME VERSION AVAILABLE PROGRESSING SINCE STATUS
version 4.6.8 True False 188d Cluster version is 4.6.8
If OpenShift is being upgrade, PROGRESSING should be True and status should be "Working towards new version".
~]$ oc get clusterversion
NAME VERSION AVAILABLE PROGRESSING SINCE STATUS
version 4.10.13 True True 9m1s Working towards 4.10.30: 97 of 773 done (12% complete)
The --output YAML or --output JSON options can be used to display more details.
~]$ oc get clusterversion --output yaml
apiVersion: v1
items:
- apiVersion: config.openshift.io/v1
kind: ClusterVersion
metadata:
creationTimestamp: "2020-10-21T18:30:38Z"
generation: 4
managedFields:
- apiVersion: config.openshift.io/v1
fieldsType: FieldsV1
fieldsV1:
f:spec:
.: {}
f:clusterID: {}
f:upstream: {}
Did you find this article helpful?
If so, consider buying me a coffee over at