Capsule sync fails with Error: Unable to update hosts ([RestClient::NotFound]: 404 Not Found) for Capsule after upgrading Red Hat Satellite 6.18
Environment
- Red Hat Satellite 6.18
- Red Hat Satellite Capsule 6.17
Issue
-
After upgrading the
Red Hat Satelliteto 6.18 and keepingRed Hat Capsuleservers to 6.17, any attempts to synchronize the external Capsule server fail with the following error:ERF12-0457 [ProxyAPI::ProxyException]: Unable to update hosts ([RestClient::NotFound]: 404 Not Found) for Capsule https://capsule.example.com:9090/container_gateway/update_hosts (ProxyAPI::ProxyException)
Resolution
-
This issue has been reported to the
Red Hat Satellite Engineeringteam via the This content is not included.JIRA SAT-41180 and is being investigated actively. -
As a workaround, if you are not using the Capsule server as a local container registry, you can disable the feature by running
satellite-installer --foreman-proxy-content-enable-docker false. If you are unsure if your Capsule is configured as a local container registry, please open a ticket with Red Hat Support. -
Meanwhile, refer to the
Diagnostic Stepsto confirm this issue and open a This content is not included.Support Case withRed Hatto know the status of the bug reported or to get a workaround. -
If it's not required to keep the capsule server on
6.17, then upgrading the version to6.18would automatically resolve the404issue.- If an issue related to
/container_gateway/update_hostsappears again, but the error message indicates a500 internal server error, please refer to this solution article and request Red Hat Support for the hotfix for the6.18version.
- If an issue related to
For more KB articles/solutions related to Red Hat Satellite 6.x Capsule Sync Issues, please refer to the Consolidated Troubleshooting Article for Red Hat Satellite 6.x Capsule Sync Issues
Root Cause
- The issue happens as the
/container_gateway/update_hosts/endpoint does not exist for Red Hat Satellite\Capsule 6.17, and hence it returns404while being accessed.
Diagnostic Steps
-
The following errors were observed in the
/var/log/foreman/production.logfile of the satellite server:2025-12-12T17:31:09 [I|app|3efb45f1] Started POST "/katello/api/capsules/capsule.example.com/content/sync" for 191.168.xxx.xxx at 2025-12-12 17:31:09 +0800 2025-12-12T17:31:09 [I|app|3efb45f1] Processing by Katello::Api::V2::CapsuleContentController#sync as HTML 2025-12-12T17:31:09 [I|app|3efb45f1] Parameters: {"id"=>"4-capsule.example.com, "skip_metadata_check"=>false, "api_version"=>"v2", "capsule_content"=>{"id"=>"4-capsule.example.com, "skip_metadata_check"=>false}} 2025-12-12T17:31:09 [I|bac|3efb45f1] Task {label: , execution_plan_id: 8b91308e-c069-40fd-bcfa-539258c0f7ec} state changed: pending 2025-12-12T17:31:09 [I|bac|3efb45f1] Task {label: Actions::Katello::CapsuleContent::Sync, id: 66abea95-e9ae-4a5c-bd8a-be4a8e27dfff, execution_plan_id: 8b91308e-c069-40fd-bcfa-539258c0f7ec} state changed: planning 2025-12-12T17:31:13 [I|bac|3efb45f1] Task {label: Actions::Katello::CapsuleContent::Sync, id: 66abea95-e9ae-4a5c-bd8a-be4a8e27dfff, execution_plan_id: 8b91308e-c069-40fd-bcfa-539258c0f7ec} state changed: planned 2025-12-12T17:31:13 [I|app|3efb45f1] Rendered /usr/share/gems/gems/katello-4.18.0.4/app/views/katello/api/v2/common/async.json.rabl within katello/api/v2/layouts/resource (Duration: 11.8ms | Allocations: 5725) 2025-12-12T17:31:13 [I|app|3efb45f1] Rendered layout /usr/share/gems/gems/katello-4.18.0.4/app/views/katello/api/v2/layouts/resource.json.erb (Duration: 12.0ms | Allocations: 5822) 2025-12-12T17:31:13 [I|app|3efb45f1] Completed 202 Accepted in 3626ms (Views: 11.0ms | ActiveRecord: 3127.4ms | Allocations: 267507) 2025-12-12T17:31:13 [I|bac|3efb45f1] Task {label: Actions::Katello::CapsuleContent::Sync, id: 66abea95-e9ae-4a5c-bd8a-be4a8e27dfff, execution_plan_id: 8b91308e-c069-40fd-bcfa-539258c0f7ec} state changed: running 2025-12-12T17:31:14 [E|bac|3efb45f1] ERF12-0457 [ProxyAPI::ProxyException]: Unable to update hosts ([RestClient::NotFound]: 404 Not Found) for Capsule https://capsule.example.com:9090/container_gateway/update_hosts (ProxyAPI::ProxyException) 3efb45f1 | /usr/share/gems/gems/katello-4.18.0.4/lib/proxy_api/container_gateway.rb:37:in `rescue in update_hosts' 3efb45f1 | /usr/share/gems/gems/katello-4.18.0.4/lib/proxy_api/container_gateway.rb:32:in `update_hosts' 3efb45f1 | /usr/share/gems/gems/katello-4.18.0.4/app/models/katello/concerns/smart_proxy_extensions.rb:251:in `update_container_gateway_hosts' 3efb45f1 | /usr/share/gems/gems/katello-4.18.0.4/app/models/katello/concerns/smart_proxy_extensions.rb:238:in `sync_container_gateway' 3efb45f1 | /usr/share/gems/gems/katello-4.18.0.4/app/lib/actions/katello/capsule_content/sync_capsule.rb:97:in `run' 3efb45f1 | /usr/share/gems/gems/dynflow-1.9.3/lib/dynflow/action.rb:590:in `block (3 levels) in execute_run' 3efb45f1 | /usr/share/gems/gems/dynflow-1.9.3/lib/dynflow/middleware/stack.rb:28:in `pass' 3efb45f1 | /usr/share/gems/gems/dynflow-1.9.3/lib/dynflow/middleware.rb:20:in `pass' 3efb45f1 | /usr/share/gems/gems/foreman-tasks-11.0.5/app/lib/actions/middleware/rails_executor_wrap.rb:14:in `block in run' 3efb45f1 | /usr/share/gems/gems/activesupport-7.0.8.7/lib/active_support/execution_wrapper.rb:92:in `wrap' 3efb45f1 | /usr/share/gems/gems/foreman-tasks-11.0.5/app/lib/actions/middleware/rails_executor_wrap.rb:13:in `run' 3efb45f1 | /usr/share/gems/gems/dynflow-1.9.3/lib/dynflow/middleware/stack.rb:24:in `call' ... ... 3efb45f1 | /usr/share/gems/gems/dynflow-1.9.3/lib/dynflow/executors/sidekiq/worker_jobs.rb:9:in `perform' 3efb45f1 | /usr/share/gems/gems/dynflow-1.9.3/lib/dynflow/executors/sidekiq/serialization.rb:28:in `perform' 3efb45f1 | [ sidekiq ] 3efb45f1 | [ concurrent-ruby ] 2025-12-12T17:31:14 [I|bac|3efb45f1] Task {label: Actions::Katello::CapsuleContent::Sync, id: 66abea95-e9ae-4a5c-bd8a-be4a8e27dfff, execution_plan_id: 8b91308e-c069-40fd-bcfa-539258c0f7ec} state changed: stopped result: warning -
The following errors were observed in the
/var/log/foreman-proxy/proxy.logfile of the affected capsule server:2025-12-12T16:51:01 [I] Execution plan cleaner removing 0 execution plans. 2025-12-12T17:21:01 [I] Execution plan cleaner removing 0 execution plans. 2025-12-12T17:31:14 3efb45f1 [I] Started PUT /container_gateway/repository_list/ 2025-12-12T17:31:14 3efb45f1 [I] Finished PUT /container_gateway/repository_list/ with 200 (1.39 ms) 2025-12-12T17:31:14 3efb45f1 [I] Started GET /container_gateway/users 2025-12-12T17:31:14 3efb45f1 [I] Finished GET /container_gateway/users with 200 (0.98 ms) 2025-12-12T17:31:14 3efb45f1 [I] Started PUT /container_gateway/update_hosts/ 2025-12-12T17:31:14 3efb45f1 [I] Finished PUT /container_gateway/update_hosts/ with 404 (1.07 ms) 2025-12-12T17:51:01 [I] Execution plan cleaner removing 0 execution plans. 2025-12-12T18:21:01 [I] Execution plan cleaner removing 0 execution plans.
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.