Repository sync tasks are failing with error "undefined method `repository_href' for nil:NilClass" after upgrading to Red Hat Satellite 6.10
Environment
- Red Hat Satellite 6.10
Issue
-
Red Hat Satellite is upgraded to version 6.10 without completing the Pulp 2 to Pulp 3 migration properly.
-
Need to complete\re-perform Pulp 2 to Pulp 3 migration after forcefully upgrading Red Hat Satellite to version 6.10.
-
Under these circumstances, The repository sync tasks are failing with the following error:
NoMethodError undefined method `repository_href' for nil:NilClass
Resolution
-
This issue has been reported to the Red Hat Engineering team via Bugzilla This content is not included.2064590 and This content is not included.2024553 and further improvements are being implemented to prevent this error from happening.
-
At present, Please restore the snapshot/backup of the Satellite sever taken prior to the upgrade activity and start upgrading again by following the steps provided by This content is not included.Red Hat Satellite Upgrade Helper.
-
If the upgrade attempt fails with suggestions of whitelisting content-switchover or content-prepare, please open a case with This content is not included.Red Hat Technical Support and share the output of the below command on the case from the Satellite server:
# satellite-maintain content migration-stats
For more KB articles/solutions related to Red Hat Satellite 6.x Repository Issues, please refer to the Red Hat Satellite Consolidated Troubleshooting Article for Red Hat Satellite 6.x Repository Issues.
Root Cause
-
The upgrade to Satellite 6.10 was forcefully performed without completing the content migration properly and by skipping one or more important steps i.e.
--whitelist="packages-update" --whitelist="content-switchover" --whitelist="installer-upgrade" -
This caused the upgraded system to have inconsistent pulp\katello database records and resulted in errors during normal content-management operations.
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.