How to gather data from a Red Hat Enterprise Linux system for troubleshooting if the sosreport process goes to hung state?

Solution Verified - Updated

Environment

  • Red Hat Enterprise Linux 5, 6, 7, 8
  • Red Hat Enterprise Linux 4.6+

Issue

  • sosreport hangs during collection.
  • sosreport does not finish as it goes to hung state.
  • How to collect data for troubleshooting?

Resolution

  • Do not interrupt the sosreport process

  • Open another terminal window

  • Change to sosreport's working directory:

    • RHEL 7, 8

        # cd /var/tmp
      
    • RHEL 6 and earlier

        # cd /tmp
      
  • Find the temporary directory where the files are being stored, it will usually be named something like <hostname>-<random number>.

  • Tar up the directory with the following command:

    # tar cvzf /tmp/`hostname`-partial-sos.tar.gz <sos temporary directory>
    
  • The file <hostname>-partial-sos.tar.gz will contain any data that was able to be collected.

Components
Category

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.