Bug 2213128 - Unable to enable any repository in network sync
Summary: Unable to enable any repository in network sync
Keywords:
Status: VERIFIED
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Inter Satellite Sync
Version: 6.12.4
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: 6.14.0
Assignee: wclark
QA Contact: Vladimír Sedmík
URL:
Whiteboard:
: 2216453 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-06-07 07:53 UTC by Hao Chang Yu
Modified: 2023-08-06 09:05 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2218653 2227900 (view as bug list)
Environment:
Last Closed:
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Hotfix RPM for Satellite 6.12.4 (10.34 MB, application/x-rpm)
2023-07-31 16:44 UTC, wclark
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 36482 0 Normal Closed Unable to enable any repository in network sync 2023-07-11 04:49:54 UTC
Red Hat Issue Tracker SAT-18239 0 None None None 2023-06-08 14:24:28 UTC

Description Hao Chang Yu 2023-06-07 07:53:12 UTC
Description of problem:
Unable to enable any repository in network sync Satellite because "Scan cdn" task failed with "No repositories available".

Go to Web Ui -> Tasks page, I found that "Scan cdn" task keeps running forever.

In production log I can see the following infinity loops.
~~~
CDN: Requesting path https://satellite.example.com:443/katello/api/v2/repository_sets?organization_id=1&search=path+%3D+%2Fcontent%2Fdist%2Frhel%2Fserver%2F7%2F%24releasever%2F%24basearch%2Fsupplementary%2Fos
CDN: Requesting path https://satellite.example.com:443/katello/api/v2/organizations/1/content_views?search=label%3DDefault_Organization_View
CDN: Requesting path https://satellite.example.com:443/katello/api/v2/organizations/1/environments?full_result=true
CDN: Requesting path https://satellite.example.com:443/katello/api/v2/repositories?full_result=true&organization_id=1&content_view_id=1&environment_id=1&search=content_label+%3D+rhel-7-server-supplementary-rpms
...
...
CDN: Requesting path https://satellite.example.com:443/katello/api/v2/repository_sets?organization_id=1&search=path+%3D+%2Fcontent%2Fdist%2Frhel%2Fserver%2F7%2F%24releasever%2F%24basearch%2Fsupplementary%2Fos
CDN: Requesting path https://satellite.example.com:443/katello/api/v2/organizations/1/content_views?search=label%3DDefault_Organization_View
CDN: Requesting path https://satellite.example.com:443/katello/api/v2/organizations/1/environments?full_result=true
CDN: Requesting path https://satellite.example.com:443/katello/api/v2/repositories?full_result=true&organization_id=1&content_view_id=1&environment_id=1&search=content_label+%3D+rhel-7-server-supplementary-rpms
~~~

Version-Release number of selected component (if applicable):
Satellite 6.12.3+
Satellite 6.13 also affected


How reproducible:
Easy


Steps to Reproduce:
1. Setup a network sync Satellite to sync with another Satellite.
2. Try to enable repository

Actual results:
No repositories can be enabled

Expected results:
Can enable repositories

Comment 3 Bryan Kearney 2023-06-21 12:03:05 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/36482 has been resolved.

Comment 4 Pavel Moravec 2023-06-22 09:50:15 UTC
*** Bug 2216453 has been marked as a duplicate of this bug. ***

Comment 6 Vladimír Sedmík 2023-07-13 10:04:01 UTC
Verified in 6.14.0 snap 7:

Steps to verify:

A) On Upstream SAT:
1) Set 'Default Red Hat Repository download policy' to immediate.
2) Uploaded manifest with subscriptions.
3) Enabled and synced several RH repos (ansible, rhel8_bos).

B) On Downstream SAT:
1) Created content credentials for the Upstream SAT.
2) In WebUI Content -> Subscriptions -> Manage Manifest -> CDN Configuration -> Network Sync -> provided Upstream SAT details (incl. CC)
3) Set 'Default Red Hat Repository download policy' to immediate.
4) Uploaded same manifest as Upstream SAT had.
5) Enabled the repos from A3) (succeeded) and synced them to Downstream SAT (succeeded). Checked the content was downloaded.
6) Tried to enable other RH repos (not synced nor enabled on the Upstream SAT) - "No repositories available." message was shown in reposet details.
In some cases (advanced-virt-crb-for-rhel-8-s390x-rpms for example) the repo appeared available on the Downstream SAT instead of the message, however, any attempt to enable it on the Downstream SAT shown proper message "Repository with content label: 'advanced-virt-crb-for-rhel-8-s390x-rpms', arch: 'noarch' was not found in upstream organization 'Default_Organization', content view 'Default_Organization_View' and lifecycle environment 'Library'"
7) Tried to enable/disable different archs within different reposets, checked they became available and could be enabled on the Downstream SAT (just enable without syncs).

Comment 7 wclark 2023-07-31 16:44:31 UTC
Created attachment 1980925 [details]
Hotfix RPM for Satellite 6.12.4

INSTALL INSTRUCTIONS:

1. Take a complete backup or snapshot of Satellite 6.12.4 server

2. Download the hotfix RPM attached to this BZ and copy it to Satellite server

3. # dnf install ./rubygem-katello-4.5.0.33-2.HOTFIXRHBZ2213128.el8sat.noarch.rpm --disableplugin=foreman-protector

4. # satellite-maintain service restart


Note You need to log in before you can comment on or make changes to this bug.