mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
193 lines
7.2 KiB
Plaintext
193 lines
7.2 KiB
Plaintext
// This module is included in the following assemblies:
|
|
//
|
|
// installing/installing_bare_metal/ipi/ipi-install-troubleshooting.adoc
|
|
|
|
:_mod-docs-content-type: PROCEDURE
|
|
[id="troubleshooting-failure-to-initialize-the-cluster_{context}"]
|
|
= Troubleshooting a failure to initialize the cluster
|
|
|
|
The installation program uses the Cluster Version Operator to create all the components of an {product-title} cluster. When the installation program fails to initialize the cluster, you can retrieve the most important information from the `ClusterVersion` and `ClusterOperator` objects.
|
|
|
|
.Procedure
|
|
|
|
. Inspect the `ClusterVersion` object by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc --kubeconfig=${INSTALL_DIR}/auth/kubeconfig get clusterversion -o yaml
|
|
----
|
|
+
|
|
.Example output
|
|
[source,yaml]
|
|
----
|
|
apiVersion: config.openshift.io/v1
|
|
kind: ClusterVersion
|
|
metadata:
|
|
creationTimestamp: 2019-02-27T22:24:21Z
|
|
generation: 1
|
|
name: version
|
|
resourceVersion: "19927"
|
|
selfLink: /apis/config.openshift.io/v1/clusterversions/version
|
|
uid: 6e0f4cf8-3ade-11e9-9034-0a923b47ded4
|
|
spec:
|
|
channel: stable-4.1
|
|
clusterID: 5ec312f9-f729-429d-a454-61d4906896ca
|
|
status:
|
|
availableUpdates: null
|
|
conditions:
|
|
- lastTransitionTime: 2019-02-27T22:50:30Z
|
|
message: Done applying 4.1.1
|
|
status: "True"
|
|
type: Available
|
|
- lastTransitionTime: 2019-02-27T22:50:30Z
|
|
status: "False"
|
|
type: Failing
|
|
- lastTransitionTime: 2019-02-27T22:50:30Z
|
|
message: Cluster version is 4.1.1
|
|
status: "False"
|
|
type: Progressing
|
|
- lastTransitionTime: 2019-02-27T22:24:31Z
|
|
message: 'Unable to retrieve available updates: unknown version 4.1.1
|
|
reason: RemoteFailed
|
|
status: "False"
|
|
type: RetrievedUpdates
|
|
desired:
|
|
image: registry.svc.ci.openshift.org/openshift/origin-release@sha256:91e6f754975963e7db1a9958075eb609ad226968623939d262d1cf45e9dbc39a
|
|
version: 4.1.1
|
|
history:
|
|
- completionTime: 2019-02-27T22:50:30Z
|
|
image: registry.svc.ci.openshift.org/openshift/origin-release@sha256:91e6f754975963e7db1a9958075eb609ad226968623939d262d1cf45e9dbc39a
|
|
startedTime: 2019-02-27T22:24:31Z
|
|
state: Completed
|
|
version: 4.1.1
|
|
observedGeneration: 1
|
|
versionHash: Wa7as_ik1qE=
|
|
----
|
|
|
|
. View the conditions by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc --kubeconfig=${INSTALL_DIR}/auth/kubeconfig get clusterversion version \
|
|
-o=jsonpath='{range .status.conditions[*]}{.type}{" "}{.status}{" "}{.message}{"\n"}{end}'
|
|
----
|
|
+
|
|
Some of most important conditions include `Failing`, `Available` and `Progressing`.
|
|
+
|
|
.Example output
|
|
[source,terminal]
|
|
----
|
|
Available True Done applying 4.1.1
|
|
Failing False
|
|
Progressing False Cluster version is 4.0.0-0.alpha-2019-02-26-194020
|
|
RetrievedUpdates False Unable to retrieve available updates: unknown version 4.1.1
|
|
----
|
|
|
|
. Inspect the `ClusterOperator` object by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc --kubeconfig=${INSTALL_DIR}/auth/kubeconfig get clusteroperator
|
|
----
|
|
+
|
|
The command returns the status of the cluster Operators.
|
|
+
|
|
.Example output
|
|
[source,terminal]
|
|
----
|
|
NAME VERSION AVAILABLE PROGRESSING FAILING SINCE
|
|
cluster-baremetal-operator True False False 17m
|
|
cluster-autoscaler True False False 17m
|
|
cluster-storage-operator True False False 10m
|
|
console True False False 7m21s
|
|
dns True False False 31m
|
|
image-registry True False False 9m58s
|
|
ingress True False False 10m
|
|
kube-apiserver True False False 28m
|
|
kube-controller-manager True False False 21m
|
|
kube-scheduler True False False 25m
|
|
machine-api True False False 17m
|
|
machine-config True False False 17m
|
|
marketplace-operator True False False 10m
|
|
monitoring True False False 8m23s
|
|
network True False False 13m
|
|
node-tuning True False False 11m
|
|
openshift-apiserver True False False 15m
|
|
openshift-authentication True False False 20m
|
|
openshift-cloud-credential-operator True False False 18m
|
|
openshift-controller-manager True False False 10m
|
|
openshift-samples True False False 8m42s
|
|
operator-lifecycle-manager True False False 17m
|
|
service-ca True False False 30m
|
|
----
|
|
|
|
. Inspect individual cluster Operators by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc --kubeconfig=${INSTALL_DIR}/auth/kubeconfig get clusteroperator <operator> -oyaml <1>
|
|
----
|
|
<1> Replace `<operator>` with the name of a cluster Operator. This command is useful for identifying why an cluster Operator has not achieved the `Available` state or is in the `Failed` state.
|
|
+
|
|
.Example output
|
|
[source,yaml]
|
|
----
|
|
apiVersion: config.openshift.io/v1
|
|
kind: ClusterOperator
|
|
metadata:
|
|
creationTimestamp: 2019-02-27T22:47:04Z
|
|
generation: 1
|
|
name: monitoring
|
|
resourceVersion: "24677"
|
|
selfLink: /apis/config.openshift.io/v1/clusteroperators/monitoring
|
|
uid: 9a6a5ef9-3ae1-11e9-bad4-0a97b6ba9358
|
|
spec: {}
|
|
status:
|
|
conditions:
|
|
- lastTransitionTime: 2019-02-27T22:49:10Z
|
|
message: Successfully rolled out the stack.
|
|
status: "True"
|
|
type: Available
|
|
- lastTransitionTime: 2019-02-27T22:49:10Z
|
|
status: "False"
|
|
type: Progressing
|
|
- lastTransitionTime: 2019-02-27T22:49:10Z
|
|
status: "False"
|
|
type: Failing
|
|
extension: null
|
|
relatedObjects: null
|
|
version: ""
|
|
----
|
|
|
|
. To get the cluster Operator's status condition, run the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc --kubeconfig=${INSTALL_DIR}/auth/kubeconfig get clusteroperator <operator> \
|
|
-o=jsonpath='{range .status.conditions[*]}{.type}{" "}{.status}{" "}{.message}{"\n"}{end}'
|
|
----
|
|
+
|
|
Replace `<operator>` with the name of one of the operators above.
|
|
+
|
|
.Example output
|
|
[source,terminal]
|
|
----
|
|
Available True Successfully rolled out the stack
|
|
Progressing False
|
|
Failing False
|
|
----
|
|
|
|
. To retrieve the list of objects owned by the cluster Operator, execute the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
oc --kubeconfig=${INSTALL_DIR}/auth/kubeconfig get clusteroperator kube-apiserver \
|
|
-o=jsonpath='{.status.relatedObjects}'
|
|
----
|
|
+
|
|
.Example output
|
|
[source,javascript]
|
|
----
|
|
[map[resource:kubeapiservers group:operator.openshift.io name:cluster] map[group: name:openshift-config resource:namespaces] map[group: name:openshift-config-managed resource:namespaces] map[group: name:openshift-kube-apiserver-operator resource:namespaces] map[group: name:openshift-kube-apiserver resource:namespaces]]
|
|
----
|