must-gather
The oc adm must-gather CLI command is used to collect information about the cluster.
Prerequisites
- Access to the cluster as a user with the
cluster-adminrole - The OpenShift Container Platform CLI (oc) command installed
- The
rsyncutility installed (optional)
Gather data about the Red Hat OpenShift Container Platform cluster
For issues with the Red Hat OpenShift Container Platform cluster where a ticket must be opened with Red Hat Support, provide the debugging information about the cluster for problem determination. For more information, see Gathering data about your cluster in Red Hat OpenShift documentation.
Executing a default must-gather for OpenShift Container Platform debug does not collect information for IBM Storage Scale container native.
Gather data about the IBM Storage Scale container native cluster
To gather data specifically for the IBM Storage Scale container native cluster to provide to IBM Support, point the must-gather tool to the ibm-spectrum-scale-must-gather image. This collects Kubernetes resources that are
associated with the IBM Storage Scale container native cluster as well as retrieving a GPFS snap.
oc adm must-gather --image requires the image that is stored in a repository where it can be anonymously pulled (no credentials required). In an airgapped environment, the ibm-spectrum-scale-must-gather image must be pulled
from the IBM Cloud Container Registry and then uploaded to an internal image registry allowing anonymous pull. For more information about air gap instructions, see Air-gapped installs.
-
In the directory where your must-gather contents are to be stored, enter the must-gather command by using the
ibm-spectrum-scale-must-gatherimage:oc adm must-gather --image=icr.io/cpopen/ibm-spectrum-scale-must-gather:v5.2.1.1By default the
gpfs.snapcommand is executed with option--limit-large-files latestby must-gather that only collects the latest large snap files. The must-gather supports to specify options ofgpfs.snapcommand to collect other data, as below:oc adm must-gather --image=icr.io/cpopen/ibm-spectrum-scale-must-gather:v5.2.1.1 -- 'gather --gpfssnap "--exclude-merge-logs --limit-large-files 2"'Custom options for gpfs.snap should be used only under instruction from IBM support.
-
Once completed, a new directory with
must-gatherprefix is created in your working directory. For example:# ls -ltr drwxr-xr-x 3 root root 229 Jun 14 09:11 must-gather.local.681612165636007567 -
Create a compressed file from the must-gather directory that was created in your working directory.
tar cvaf must-gather.tar.gz must-gather.local.681612165636007567/Replace the directory name used in this example with your respective must-gather directory.