Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2208310 - 'Remove orphans' task fails on DeleteOrphanAlternateContentSources step
Summary: 'Remove orphans' task fails on DeleteOrphanAlternateContentSources step
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Alternate Content Sources
Version: 6.13.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: 6.15.0
Assignee: Samir Jha
QA Contact: Vladimír Sedmík
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-05-18 14:44 UTC by Jan Senkyrik
Modified: 2024-04-23 17:11 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2266149 (view as bug list)
Environment:
Last Closed: 2024-04-23 17:11:14 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 36461 0 Normal Closed 'Remove orphans' task fails on DeleteOrphanAlternateContentSources step 2023-09-08 11:06:12 UTC
Red Hat Issue Tracker SAT-17849 0 None None None 2023-05-22 13:23:07 UTC
Red Hat Product Errata RHSA-2024:2010 0 None None None 2024-04-23 17:11:16 UTC

Description Jan Senkyrik 2023-05-18 14:44:22 UTC
Description of problem:
Remove orphans task fails on Capsule servers. It executes successfully on the Satellite server itself.

Here are task details:

# hammer task info --id 19c79c4f-eaea-4739-bea0-a8aec0f595c0
~~~
ID:          19c79c4f-eaea-4739-bea0-a8aec0f595c0
Action:      Remove orphans
State:       paused
Result:      error
Started at:  2023/05/14 20:00:28
Ended at:
Duration:    61876.254165
Owner:       foreman_admin
Task errors: undefined method `pulp3_api' for nil:NilClass

Details:
Errors: undefined method `pulp3_api' for nil:NilClass
Action: Actions::Pulp3::OrphanCleanup::DeleteOrphanAlternateContentSources
Exception: NoMethodError: undefined method `pulp3_api' for nil:NilClass
Stack: 2023-05-14T22:00:58 [E|bac|] undefined method `pulp3_api' for nil:NilClass (NoMethodError)
 | /usr/share/gems/gems/katello-4.7.0.23/app/services/katello/pulp3/repository.rb:42:in `api'
 | /usr/share/gems/gems/katello-4.7.0.23/app/services/katello/pulp3/smart_proxy_mirror_repository.rb:82:in `delete_orphan_alternate_content_sources'
 | /usr/share/gems/gems/katello-4.7.0.23/app/lib/actions/pulp3/orphan_cleanup/delete_orphan_alternate_content_sources.rb:11:in `invoke_external_task'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/action/polling.rb:84:in `initiate_external_action'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/action/polling.rb:19:in `run'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/action/cancellable.rb:14:in `run'
 | /usr/share/gems/gems/katello-4.7.0.23/app/lib/actions/pulp3/abstract_async_task.rb:10:in `run'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/action.rb:582:in `block (3 levels) in execute_run'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:27:in `pass'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware.rb:19:in `pass'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware.rb:32:in `run'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:23:in `call'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:27:in `pass'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware.rb:19:in `pass'
 | /usr/share/gems/gems/katello-4.7.0.23/app/lib/actions/middleware/remote_action.rb:16:in `block in run'
 | /usr/share/gems/gems/katello-4.7.0.23/app/lib/actions/middleware/remote_action.rb:40:in `block in as_remote_user'
 | /usr/share/gems/gems/katello-4.7.0.23/app/models/katello/concerns/user_extensions.rb:21:in `cp_config'
 | /usr/share/gems/gems/katello-4.7.0.23/app/lib/actions/middleware/remote_action.rb:27:in `as_cp_user'
 | /usr/share/gems/gems/katello-4.7.0.23/app/lib/actions/middleware/remote_action.rb:39:in `as_remote_user'
 | /usr/share/gems/gems/katello-4.7.0.23/app/lib/actions/middleware/remote_action.rb:16:in `run'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:23:in `call'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:27:in `pass'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware.rb:19:in `pass'
 | /usr/share/gems/gems/foreman-tasks-7.2.1/app/lib/actions/middleware/rails_executor_wrap.rb:14:in `block in run'
 | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/execution_wrapper.rb:91:in `wrap'
 | /usr/share/gems/gems/foreman-tasks-7.2.1/app/lib/actions/middleware/rails_executor_wrap.rb:13:in `run'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:23:in `call'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:27:in `pass'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware.rb:19:in `pass'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/action/progress.rb:31:in `with_progress_calculation'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/action/progress.rb:17:in `run'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:23:in `call'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:27:in `pass'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware.rb:19:in `pass'
 | /usr/share/gems/gems/foreman-tasks-7.2.1/app/lib/actions/middleware/load_setting_values.rb:20:in `run'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:23:in `call'
 | /usr/share/gems/gems/dynflow-1.6.10/lib/dynflow/middleware/stack.rb:27:in `pass'
~~~


Version-Release number of selected component (if applicable):
Satellite 6.13

How reproducible:
N/A

Comment 1 Adam Ruzicka 2023-05-18 14:47:28 UTC
This looks like something that needs to be handled in katello, not in tasks as an engine.

Comment 4 Samir Jha 2023-06-01 14:24:06 UTC
Created redmine issue https://projects.theforeman.org/issues/36461 from this bug

Comment 5 Bryan Kearney 2023-06-14 16:03:15 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/36461 has been resolved.

Comment 7 Vladimír Sedmík 2024-01-23 21:23:33 UTC
Reproduced in 6.13.6, verified in 6.15.0 snap 7.0 - the Remove orphans task succeeded when the file content was disabled on the external capsule and mocked in smart_proxy_mirror_repository.rb.

Comment 10 errata-xmlrpc 2024-04-23 17:11:14 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.15.0 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-2024:2010


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