Bug 1913470

Summary: Migration plugin can't query content from mongo in order
Product: Red Hat Satellite Reporter: Tanya Tereshchenko <ttereshc>
Component: PulpAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED ERRATA QA Contact: Lai <ltran>
Severity: high Docs Contact:
Priority: unspecified    
Version: 6.8.0CC: bmbouter, ggainey, ipanova, rchan, swadeley, ttereshc, zhunting
Target Milestone: 6.9.0Keywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Fixed In Version: pulp-2.21.5 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-04-21 13:25:02 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:

Description Tanya Tereshchenko 2021-01-06 20:47:26 UTC
Description of problem:
To ensure data correctness, pulp 2to3 migration requires fetching content in ordered way
no index for _last_updated on content models causes a fatal error when ordered result is queried.

Version-Release number of selected component (if applicable):
pulp 2.21.4

Comment 2 pulp-infra@redhat.com 2021-01-06 21:09:41 UTC
The Pulp upstream bug status is at ASSIGNED. Updating the external tracker on this bug.

Comment 3 pulp-infra@redhat.com 2021-01-06 21:09:42 UTC
The Pulp upstream bug priority is at Normal. Updating the external tracker on this bug.

Comment 4 pulp-infra@redhat.com 2021-01-13 13:43:07 UTC
The Pulp upstream bug status is at POST. Updating the external tracker on this bug.

Comment 5 pulp-infra@redhat.com 2021-01-15 16:34:32 UTC
The Pulp upstream bug status is at MODIFIED. Updating the external tracker on this bug.

Comment 6 pulp-infra@redhat.com 2021-01-15 19:46:16 UTC
All upstream Pulp bugs are at MODIFIED+. Moving this bug to POST.

Comment 7 pulp-infra@redhat.com 2021-01-25 20:31:36 UTC
The Pulp upstream bug status is at CLOSED - CURRENTRELEASE. Updating the external tracker on this bug.

Comment 9 Tanya Tereshchenko 2021-03-09 18:54:08 UTC
Hi Stephen,

Steps to verify:

1. Sync couple of large repositories with Pulp <= 2.21.4, e.g. RHEL7 and RHEL8 BaseOS and Appstream
2. Try to run migration from pulp 2 to pulp 3 using pulp-2to3-migration>=0.7.0.
It should fail.

Upgrade pulp2 to 2.21.5 and run migration again, observe no failure.

Not sure if the combinations of versions required to test it exist with the product.
In the worst case, you can just check that the same steps just for pulp 2.21.5 and pulp-2to3-migration >= 0.7.0 produce no error.

Comment 10 Lai 2021-03-16 17:49:45 UTC
Steps to retest:

As mentioned in comment #9 above, I have followed her steps, but only did RHEL8 BaseOS and Appstream.  The syncing and migration was both successfull on pulp-rpm-plugins-2.21.5-2.el7sat.noarch, pulp-server-2.21.5-2.el7sat.noarch, and python3-pulp-2to3-migration-0.9.1-1.el7pc.noarch.

Verified on 6.9.0_017

Comment 13 errata-xmlrpc 2021-04-21 13:25:02 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 (Moderate: Satellite 6.9 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.