Bug 2169866

Summary: Exporting the Library environment incrementally fails with error "Incremental export can only be requested when there is a previous export or start_versions= has been specified."
Product: Red Hat Satellite Reporter: Jayant Bhatia <jbhatia>
Component: Inter Satellite SyncAssignee: Partha Aji <paji>
Status: CLOSED ERRATA QA Contact: Samir Jha <sajha>
Severity: high Docs Contact:
Priority: high    
Version: 6.13.0CC: ahumbe, iballou, paji, pcreech, sajha, vsedmik
Target Milestone: 6.13.0Keywords: Regression, Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: tfm-rubygem-katello-4.7.0.15-1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-05-03 13:25:08 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jayant Bhatia 2023-02-14 21:11:08 UTC
Description of problem:

Running "# hammer content-export incremental library --organization="RedHat"" command on Satellite server fails with below error.
~~~
Error: Error message: the server returns an error
HTTP status code: 400
Response headers: {"Date"=>"Tue, 14 Feb 2023 20:55:40 GMT", "Server"=>"gunicorn", "Content-Type"=>"application/json", "Vary"=>"Accept,Cookie", "Allow"=>"GET, POST, HEAD, OPTIONS", "X-Frame-Options"=>"DENY", "Content-Length"=>"136", "X-Content-Type-Options"=>"nosniff", "Referrer-Policy"=>"same-origin", "Correlation-ID"=>"b4463ab7-828a-4bf8-9839-eafcc3634cb0", "Access-Control-Expose-Headers"=>"Correlation-ID", "Via"=>"1.1 satellite.example.com", "Connection"=>"close"}
Response body: {"non_field_errors":["Incremental export can only be requested when there is a previous export or start_versions= has been specified."]}
undefined method `output_file_info' for nil:NilClass
~~~


Version-Release number of selected component (if applicable): satellite-6.13.0-4.el8sat.noarch


How reproducible: Always


Steps to Reproduce:

1. Run below command on Satellite to export the Library environment.

       # hammer content-export complete library --organization="My_Organization

2. The required directory is created within "/var/lib/pulp/exports/My_Organization/Export-Library"

3. Run following command to export Library environment incrementally:

       # hammer content-export incremental library --organization="My_Organization"


Actual results: The command fails with below error:

Error: Error message: the server returns an error
HTTP status code: 400
Response headers: {"Date"=>"Tue, 14 Feb 2023 20:55:40 GMT", "Server"=>"gunicorn", "Content-Type"=>"application/json", "Vary"=>"Accept,Cookie", "Allow"=>"GET, POST, HEAD, OPTIONS", "X-Frame-Options"=>"DENY", "Content-Length"=>"136", "X-Content-Type-Options"=>"nosniff", "Referrer-Policy"=>"same-origin", "Correlation-ID"=>"b4463ab7-828a-4bf8-9839-eafcc3634cb0", "Access-Control-Expose-Headers"=>"Correlation-ID", "Via"=>"1.1 dhcp131-67.gsslab.pnq2.redhat.com", "Connection"=>"close"}
Response body: {"non_field_errors":["Incremental export can only be requested when there is a previous export or start_versions= has been specified."]}
undefined method `output_file_info' for nil:NilClass


Expected results: The command should get executed successfully.


Additional info: Following steps as per Section-8.2 and Section-8.4 from following documentation: https://dxp-docp-prod.apps.ext-waf.spoke.prod.us-west-2.aws.paas.redhat.com/documentation/en-us/red_hat_satellite/6.13/html-single/managing_content/index?lb_target=preview

This issue is not observed on Satellite 6.12.

Comment 5 Partha Aji 2023-02-27 18:34:36 UTC
Connecting redmine issue https://projects.theforeman.org/issues/36146 from this bug

Comment 7 Bryan Kearney 2023-02-27 20:03:37 UTC
Upstream bug assigned to paji

Comment 8 Bryan Kearney 2023-02-27 20:03:39 UTC
Upstream bug assigned to paji

Comment 9 Bryan Kearney 2023-02-27 20:03:49 UTC
Upstream bug assigned to paji

Comment 10 Bryan Kearney 2023-02-27 20:03:51 UTC
Upstream bug assigned to paji

Comment 22 errata-xmlrpc 2023-05-03 13:25:08 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 (Important: Satellite 6.13 Release), 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/RHSA-2023:2097