Bug 2059374

Summary: hammer repository upload-content with large file gives "Too many open files" error
Product: Red Hat Satellite Reporter: Brad Buckingham <bbuckingham>
Component: PulpAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED ERRATA QA Contact: Lukáš Hellebrandt <lhellebr>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.10.0CC: ahumbe, bbuckingham, dkliban, lhellebr, sadas, saydas, zhunting
Target Milestone: 6.10.4Keywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: pulpcore-3.14.13-1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 2034317 Environment:
Last Closed: 2022-03-29 14:48:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Comment 3 Lukáš Hellebrandt 2022-03-16 17:49:58 UTC
Verified with Sat 6.10.4 snap 2.0.

CLI:
# wget https://releases.ubuntu.com/20.04/ubuntu-20.04.4-desktop-amd64.iso
# hammer repository upload-content --id 8 --content-type file --path ubuntu-20.04.4-desktop-amd64.iso
# wget https://<SAT_FQDN>/pulp/content/Default_Organization/Library/custom/testprod/testrepo/ubuntu-20.04.4-desktop-amd64.iso
# md5sum ubuntu-20.04.4-desktop-amd64.iso
ca0c7f1cf362eef25f54f6cd61c5fdba  ubuntu-20.04.4-desktop-amd64.iso
# md5sum ubuntu-20.04.4-desktop-amd64.iso.1
ca0c7f1cf362eef25f54f6cd61c5fdba  ubuntu-20.04.4-desktop-amd64.iso.1

API:
# curl -u admin:changeme -H Accept:application/json -H Content-Type:multipart/form-data -X POST https://$(hostname)//katello/api/repositories/8/upload_content -F content_type=file -F content=@onegbfile
{"status":"success","filenames":["onegbfile"]}
# curl -u admin:changeme -H Accept:application/json -H Content-Type:multipart/form-data -X POST https://$(hostname)//katello/api/repositories/8/upload_content -F content_type=file -F content=@threegbfile
{"displayMessage":"The time waiting for task 24c1707b-871f-46c3-89f1-a384d643dbe7 to finish exceeded the 'foreman_tasks_sync_task_timeout' (120s)","errors":["The time waiting for task 24c1707b-871f-46c3-89f1-a384d643dbe7 to finish exceeded the 'foreman_tasks_sync_task_timeout'
# The above failure is expected, this endpoint is intended for small files. Large files should be uploaded as described in https://access.redhat.com/solutions/2975281 when using API.

Comment 8 errata-xmlrpc 2022-03-29 14:48:55 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Satellite 6.10.4 Async Bug Fix Update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2022:1116