How To
Summary
This document explains how to install the SUPPORT-TOOLS container image in both internet-connected and air-gapped environments and outlines the process for collecting diagnostic data from Legacy Red Hat Enterprise Linux operating systems. This data might be necessary for hardware and software problem determination. Additionally, the document offers guidance on how to transmit the collected data to IBM.
Objective
- The `sos report` and `IBM Power Systems service and productivity tools` are critical for system diagnostics and troubleshooting in Linux environments and need to be updated regularly. For further details, refer to 'Installing and Updating the sos report'.
- For users of legacy Red Hat Enterprise Linux (RHEL) 6 and 7 on IBM Power Servers, it is essential to understand how to install, run, and manage the SUPPORT-TOOLS container image.
- This document offers a comprehensive guide on effectively installing, running, and managing the SUPPORT-TOOLS container image in internet-connected and air-gapped environments, as well as how to collect log data from legacy Red Hat Enterprise Linux (RHEL) systems.
Environment
- The system can be any IBM Power Servers running Linux.
- List of POWER10 Servers running Linux.
- List of POWER8 and POWER9 Servers running Linux.
- List of POWER6 and POWER7 Servers running Linux.
Steps
- To use `podman` and pull the support-tools container image, first log in to the registry at registry.redhat.io
[root@sos ~]# podman login registry.redhat.io Username: borislav.ivanov.stoymirski Password: Login Succeeded! - To successfully install and execute the support-tools container image on IBM Power Servers running RHEL 7.9, and to efficiently collect an sos report archive from the host within the container image, the following command should be run:
podman container runlabel RUN registry.redhat.io/rhel8/support-tools(This command install and RUN the SOS package on RHEL 7.9)Trying to pull registry.redhat.io/rhel8/support-tools:latest... Getting image source signatures Checking if image destination supports signatures Copying blob a7dde6f953b3 done Copying blob 068f2e6b47b2 done Copying config e8aa68d02c done Writing manifest to image destination Storing signaturesNote:
If a message, "Error: creating container storage: the container name "support-tools" is already in use by 828bd4de6a68cc4dbc1cc41c43cd2cba9920f84d29373496fa4f1aa357faf400. You have to remove that container to be able to reuse that name: that name is already in use
Error: `/proc/self/exe run -it --name support-tools --privileged --ipc=host --net=host --pid=host -e HOST=/host -e NAME=support-tools -e IMAGE=registry.redhat.io/rhel8/support-tools:latest -v /run:/run -v /var/log:/var/log -v /etc/machine-id:/etc/machine-id -v /etc/localtime:/etc/localtime -v /:/host registry.redhat.io/rhel8/support-tools:latest` failed: exit status 125" , is displayed on the terminal after running the 'podman' command, type `sudo podman rm support-tools` to remove the `support-tools` container and rerun the 'podman' command to avoid issues with `sos report`.[root@Sos ~]# sudo podman rm support-tools support-toolsTo verify that you are connected and operating within asupport-toolscontainer, you can view environment variable by running:[root@sos /]# env | grep -i image IMAGE=registry.redhat.io/rhel8/support-tools:latestPart 2: Air-gapped environmentIn an air-gapped environment, we first need to ensure that the container image is mirrored within an internal or private repository before installation. Alternatively, we can pull the container image (using podman pull), save it (podman image save), and transfer it as an archive from another system connected to the internet. Then, load the image on the target host using podman image load.Note: Installing a container image from a private repository is similar to Part 1 in the instructions above. Therefore, in the following steps, we will cover how to pull the container image (using podman pull), save it (podman image save), and transfer it as an archive from a system connected to the internet to a target host in disconnected environments. Then, we'll demonstrate how to load the image.- Fist on internet connected environment pull the container image as described in Part 1 in the instructions above. Next save the container image with following command:
Part 3: How to generate a new sosreport archive from the Support-Tools container~]# podman image save -o rhel8-support-tools.tar.gz registry.redhat.io/rhel8/support-tools Copying blob 1a043bbc7a1a done Copying blob 38037578736a done Copying config e8aa68d02c done Writing manifest to image destination ~]# ls -l rhel8-support-tools.tar.gz -rw-r--r--. 1 root root 339899392 Jan 5 09:46 rhel8-support-tools.tar.gz- Transfer the 'rhel8-support-tools.tar.gz' archive to the disconnected system either by authenticating through the firewall using an SFTP server or by using a USB/DVD drive, depending on the recommendations from your IT security department.
- Once the tar.gz archive has been transferred to the target host, run the following command to load the image:
~]# ls -l rhel8-support-tools.tar.gz -rw-r--r--. 1 root root 339899392 Jan 5 09:46 rhel8-support-tools.tar.gz ~]# podman image load -i rhel8-support-tools.tar.gz Getting image source signatures Copying blob 38037578736a done Copying blob 1a043bbc7a1a done Copying config e8aa68d02c done Writing manifest to image destination Loaded image: registry.redhat.io/rhel8/support-tools:latest - Ensure that the container image is loaded correctly by utilizing the following command:
~]# podman images -a REPOSITORY TAG IMAGE ID CREATED SIZE registry.redhat.io/rhel8/support-tools latest e8aa68d02c27 8 weeks ago 340 MB - In case of an issue with the container image, it can be removed by executing the following command and using the IMAGE ID. In our case, the IMAGE ID is e8aa68d02c27:
~]# podman rmi e8aa68d02c27 Untagged: registry.redhat.io/rhel8/support-tools:latest Deleted: e8aa68d02c27820f90a016fcfb13d8669bdf32e17527ee3166cefe46bbc54cf6
- To execute the support-tools container image on IBM Power Servers running RHEL 7.x, and to efficiently collect an sos report archive from the host within the container image, the following command should be run:
podman container runlabel RUN registry.redhat.io/rhel8/support-tools - First, ensure that you are connected and operating within a support-tools container. You can view the environment variables by running:
[root@sos /]# env | grep -i image IMAGE=registry.redhat.io/rhel8/support-tools:latest- Next, generate a new `sosreport` archive by running the `sos report` command:
[root@sos /]# sos report sosreport (version 4.6.0) This command will collect diagnostic and configuration information from this Red Hat Enterprise Linux system and installed applications. An archive containing the collected information will be generated in /host/var/tmp/sos.s_2own11 and may be provided to a Red Hat support representative. Any information provided to Red Hat will be treated in accordance with the published support policies at: Distribution Website : https://www.redhat.com/ Commercial Support : https://access.redhat.com/ Creating compressed archive... Your sosreport has been generated and saved in: /host/var/tmp/sosreport-sos-podmansos-2023-11-25-kyarksu.tar.xz Size 21.77MiB Owner root sha256 7e93464ca5246991cbe3cf098d8ef3ba3d018c133152c31bf81a6e32308b1e4b Please send this file to your support representative.Press ENTER to continue, or CTRL+C to quit.
When instructed to “enter the case ID that you are generating this report for []”, type: <IBM or Red Hat case number >
A file called "sosreport-nodename-currentdate.tar.xz" is created in “/host/var/tmp/sosreport-nodename-currentdate.tar.xz“- Exit the `support-tools` container by using `Ctrl+C` in the Terminal or detach from the container without stopping it with `Ctrl+P` followed by ` Ctrl+Q`.
- To see all containers, including those that have exited or stopped, use and copy the <Container ID>:
[root@sos ~]# podman ps -a CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 145fb3e77c4f registry.redhat.io/rhel8/support-tools:latest /usr/bin/bash 10 minutes ago Exited (0) 9 minutes ago support-tools - Use
podman cpto Copy the File: Thepodman cpcommand allows you to copy files between a container and the local filesystem. To copy a file from a container to the host, use:
For instance, if ourpodman cp <container_id>:/path/in/container /path/on/host<container_id>is145fb3e77c4f, the following command can be used to copy the`sosreport`archive to the target host:[root@sos ~]# podman cp 145fb3e77c4f:/host/var/tmp/sosreport-sos-podmansos-2023-11-25-kyarksu.tar.xz /root/sosreport-sos-podmansos-2023-11-25-kyarksu.tar.xz -
To return to a container that is still running, you can use the
podman attachcommand if you want to attach to a container's STDIN, STDOUT, and STDERR, orpodman execto start a new process inside a running container. Here's how you can do it:-
Using
podman attach:- If you want to reattach to the container's main process (for instance, if it's a shell), use:
podman attach <container_id_or_name>(This command will reconnect you to the terminal session you detached from if the container is still running.)
- If you want to reattach to the container's main process (for instance, if it's a shell), use:
-
Using
podman exec:- If you want to execute a new command or open a new shell inside a running container, use:
podman exec -it <container_id_or_name> /bin/bash - For instance, if our
<container_id>is145fb3e77c4f, the following command can be used to execute a new command or open a new shell:[root@sos ~]# podman ps -a CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 145fb3e77c4f registry.redhat.io/rhel8/support-tools:latest /usr/bin/bash 10 minutes ago Exited (0) 9 minutes ago support-tools [root@sos ~]# podman exec -it 145fb3e77c4f /bin/bash - Here,
/bin/bashis an example. It opens a bash shell inside the container. You can replace/bin/bashwith any command you wish to run inside the container. - The
-itflag is used for interactive processes, like a shell.
- If you want to execute a new command or open a new shell inside a running container, use:
-
Part 4: Transfer the log data to the existing IBM case via Ecurep URL:- Transfer the `sos report` archive to the target system.
[root@sos /]# ls /host/var/tmp/sosreport-sos-podmansos-2023-11-25-kyarksu.tar.xz /host/var/tmp/sosreport-wgpuos-podmansos-2023-11-25-kyarksu.tar.xz -
If required, transfer the file to a system with internet access. When using FTP as a protocol, make sure to use the binary transfer method.
-
Prepare the diagnostic data:
https://www.ibm.com/support/pages/node/739597
Send the diagnostic data to IBM:
https://www.ibm.com/support/pages/enhanced-customer-data-repository-ecurep-send-data
Secure upload the file to an existing IBM case via Ecurep URL:
Document Location
Worldwide
Was this topic helpful?
Document Information
Modified date:
05 January 2024
UID
ibm17105490