From cf1908ebfa6f1ba6e208aa8a9fdc88284600bf17 Mon Sep 17 00:00:00 2001 From: Sebastian Kopacz Date: Thu, 31 Aug 2023 11:33:52 -0400 Subject: [PATCH] OSDOCS-7442: Agent data gathering --- ...installing-with-agent-based-installer.adoc | 4 ++ modules/installing-ocp-agent-ZTP.adoc | 2 +- modules/installing-ocp-agent-boot.adoc | 2 +- modules/installing-ocp-agent-download.adoc | 2 +- modules/installing-ocp-agent-encrypt.adoc | 2 +- modules/installing-ocp-agent-gather-log.adoc | 71 +++++++++++++++++++ modules/installing-ocp-agent-inputs.adoc | 2 +- modules/installing-ocp-agent-tui.adoc | 2 +- modules/installing-ocp-agent-verify.adoc | 2 +- modules/sample-ztp-custom-resources.adoc | 2 +- 10 files changed, 83 insertions(+), 8 deletions(-) create mode 100644 modules/installing-ocp-agent-gather-log.adoc diff --git a/installing/installing_with_agent_based_installer/installing-with-agent-based-installer.adoc b/installing/installing_with_agent_based_installer/installing-with-agent-based-installer.adoc index 2e817d1061..edcd66511d 100644 --- a/installing/installing_with_agent_based_installer/installing-with-agent-based-installer.adoc +++ b/installing/installing_with_agent_based_installer/installing-with-agent-based-installer.adoc @@ -74,3 +74,7 @@ include::modules/sample-ztp-custom-resources.adoc[leveloffset=+1] .Additional resources * See xref:../../scalability_and_performance/ztp_far_edge/ztp-deploying-far-edge-clusters-at-scale.adoc#ztp-deploying-far-edge-clusters-at-scale[Challenges of the network far edge] to learn more about {ztp-first}. + + +// Gathering log data from a failed Agent-based installation +include::modules/installing-ocp-agent-gather-log.adoc[leveloffset=+1] \ No newline at end of file diff --git a/modules/installing-ocp-agent-ZTP.adoc b/modules/installing-ocp-agent-ZTP.adoc index ffceaf759e..4c074e539f 100644 --- a/modules/installing-ocp-agent-ZTP.adoc +++ b/modules/installing-ocp-agent-ZTP.adoc @@ -1,6 +1,6 @@ // Module included in the following assemblies: // -// * installing-with-agent/installing-with-agent.adoc +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc :_content-type: PROCEDURE [id="installing-ocp-agent-ztp_{context}"] diff --git a/modules/installing-ocp-agent-boot.adoc b/modules/installing-ocp-agent-boot.adoc index a3c803b208..5ee3d015d6 100644 --- a/modules/installing-ocp-agent-boot.adoc +++ b/modules/installing-ocp-agent-boot.adoc @@ -1,6 +1,6 @@ // Module included in the following assemblies: // -// * installing-with-agent/installing-with-agent-based-installer.adoc +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc :_content-type: PROCEDURE [id="installing-ocp-agent-boot_{context}"] diff --git a/modules/installing-ocp-agent-download.adoc b/modules/installing-ocp-agent-download.adoc index 45f41be54c..edd04d2487 100644 --- a/modules/installing-ocp-agent-download.adoc +++ b/modules/installing-ocp-agent-download.adoc @@ -1,6 +1,6 @@ // Module included in the following assemblies: // -// * installing-with-agent/installing-with-agent.adoc +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc :_content-type: PROCEDURE [id="installing-ocp-agent-retrieve_{context}"] diff --git a/modules/installing-ocp-agent-encrypt.adoc b/modules/installing-ocp-agent-encrypt.adoc index 46b4fc1182..03088b1863 100644 --- a/modules/installing-ocp-agent-encrypt.adoc +++ b/modules/installing-ocp-agent-encrypt.adoc @@ -1,6 +1,6 @@ // Module included in the following assemblies: // -// * installing-with-agent/installing-with-agent-based-installer.adoc +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc :_content-type: PROCEDURE [id="installing-ocp-agent-encrypt_{context}"] diff --git a/modules/installing-ocp-agent-gather-log.adoc b/modules/installing-ocp-agent-gather-log.adoc new file mode 100644 index 0000000000..afc242feb8 --- /dev/null +++ b/modules/installing-ocp-agent-gather-log.adoc @@ -0,0 +1,71 @@ +// Module included in the following assemblies: +// +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc + +:_content-type: PROCEDURE +[id="installing-ocp-agent-gather-log_{context}"] += Gathering log data from a failed Agent-based installation + +Use the following procedure to gather log data about a failed Agent-based installation to provide for a support case. + +.Procedure + +. Run the following command and collect the output: ++ +[source,terminal] +---- +$ ./openshift-install --dir agent wait-for bootstrap-complete --log-level=debug +---- ++ +.Example error message +[source,terminal] +---- +... +ERROR Bootstrap failed to complete: : bootstrap process timed out: context deadline exceeded +---- + +. If the output from the previous command indicates a failure, or if the bootstrap is not progressing, run the following command on node 0 and collect the output: ++ +[source,terminal] +---- +$ ssh core@ sudo /usr/local/bin/agent-gather -O > /agent-gather.tar.xz +---- ++ +[NOTE] +==== +You only need to gather data from node 0, but gathering this data from every node can be helpful. +==== + +. If the bootstrap completes and the cluster nodes reboot, run the following command and collect the output: ++ +[source,terminal] +---- +$ ./openshift-install --dir agent wait-for install-complete --log-level=debug +---- + +. If the output from the previous command indicates a failure, perform the following steps: + +.. Export the `kubeconfig` file to your environment by running the following command: ++ +[source,terminal] +---- +$ export KUBECONFIG=/auth/kubeconfig +---- + +.. To gather information for debugging, run the following command: ++ +[source,terminal] +---- +$ oc adm must-gather +---- + +.. Create a compressed file from the `must-gather` directory that was just created in your working directory by running the following command: ++ +[source,terminal] +---- +$ tar cvaf must-gather.tar.gz +---- + +. Excluding the `/auth` subdirectory, attach the installation directory used during the deployment to your support case on the link:https://access.redhat.com[Red Hat Customer Portal]. + +. Attach all other data gathered from this procedure to your support case. \ No newline at end of file diff --git a/modules/installing-ocp-agent-inputs.adoc b/modules/installing-ocp-agent-inputs.adoc index c5990dd7ad..f340f22d8f 100644 --- a/modules/installing-ocp-agent-inputs.adoc +++ b/modules/installing-ocp-agent-inputs.adoc @@ -1,6 +1,6 @@ // Module included in the following assemblies: // -// * installing-with-agent/installing-with-agent-based-installer.adoc +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc :_content-type: PROCEDURE [id="installing-ocp-agent-inputs_{context}"] diff --git a/modules/installing-ocp-agent-tui.adoc b/modules/installing-ocp-agent-tui.adoc index 4d21bbc747..e087a486c5 100644 --- a/modules/installing-ocp-agent-tui.adoc +++ b/modules/installing-ocp-agent-tui.adoc @@ -1,6 +1,6 @@ // Module included in the following assemblies: // -// * installing-with-agent/installing-with-agent.adoc +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc :_content-type: PROCEDURE [id="installing-ocp-agent-tui_{context}"] diff --git a/modules/installing-ocp-agent-verify.adoc b/modules/installing-ocp-agent-verify.adoc index b30e0fdb00..6c196520d7 100644 --- a/modules/installing-ocp-agent-verify.adoc +++ b/modules/installing-ocp-agent-verify.adoc @@ -1,6 +1,6 @@ // Module included in the following assemblies: // -// * installing-with-agent/installing-with-agent.adoc +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc :_content-type: PROCEDURE [id="installing-ocp-agent-verify_{context}"] diff --git a/modules/sample-ztp-custom-resources.adoc b/modules/sample-ztp-custom-resources.adoc index 15cc8a0549..09c1c455df 100644 --- a/modules/sample-ztp-custom-resources.adoc +++ b/modules/sample-ztp-custom-resources.adoc @@ -1,6 +1,6 @@ // Module included in the following assemblies: // -// * installing-with-agent/installing-with-agent.adoc +// * installing/installing-with-agent-based-installer/installing-with-agent-based-installer.adoc :_content-type: CONCEPT [id="sample-ztp-custom-resources_{context}"]