Failed to upload openscap compliance report to the Red Hat Satellite 6 with an error "Net::ReadTimeout"

Solution Verified - Updated

Environment

  • Red Hat Satellite 6.6 and above
  • Red Hat Satellite Capsule Server 6.6 and above

Issue

  • Unable to upload Openscap report to the Red Hat Satellite 6 server after the scanning has been completed.

    Jan 01 xx:xx:xx host1 foreman_scap_client[3552]: Uploading results to https://satellite.example.com:9090/compliance/arf/6
    Jan 01 xx:xx:xx host1 foreman_scap_client[3552]: Upload failed: Net::ReadTimeout
    

Resolution

  • As explained in the Root Cause section of this solution article, The timeout error during openscap report upload can be happening due to load on the web-server around the same time and increasing the default timeout value can help to get the upload task completed.

  • Run the following command in the Red Hat Satellite server, to increase the upload timeout of the openscap plugin:

     # satellite-installer --foreman-proxy-plugin-openscap-timeout 360
    
  • Verify the new timeout settings from /etc/foreman-proxy/settings.d/openscap.yml file.

    # cat /etc/foreman-proxy/settings.d/openscap.yml | grep -i timeout
    # Timeout to send ARF reports to Foreman, in seconds
    : timeout: 360
    
  • Reach out to the This content is not included.Red Hat Technical Support, if the issue still persists and further investigation is required.

 

For more KB articles/solutions related to Red Hat Satellite 6.x OpenSCAP Issues, please refer to the Red Hat Satellite Consolidated Troubleshooting Article for Red Hat Satellite 6.x OpenSCAP Issues.

Root Cause

  • The error Net::ReadTimeout usually indicates that a TCP connection is established, but the application is not sending data back to the client (client cannot read data). This can happen if the application side is too busy, slow, or lacking resources to reply in a reasonable amount of time and can further be analyzed based on the configuration options that are set up on the Red Hat Satellite server.

  • After the scanning is completed, the Client sends the file to the foreman-proxy. Foreman-proxy sends it to the foreman. Foreman will process the report and store the data in the database. If the database takes more time to process that data than the timeout value configured on foreman-proxy, then the timeout occurs.

SBR
Product(s)
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.