Remove orphans error

Problem:
I am getting some errors by Remove orphans:

(“Cannot delete some instances of model ‘Content’ because they are referenced through protected foreign keys: ‘Package.content_ptr’.”, {<RepositoryContent: pk=442d638a-2fe8-4dca-b282-e2dfa4590a9c>, <RepositoryContent: pk=b9181c1c-d9b0-413f-ae54-26ac03ebbf60>, <RepositoryContent: pk=9253abde-4d19-4239-b130-dce35a07cc52>})

(“Cannot delete some instances of model ‘Content’ because they are referenced through protected foreign keys: ‘ReleaseFile.content_ptr’.”, {<RepositoryContent: pk=a9b41ffd-966c-4bae-a62e-babb902eceaa>})

Expected outcome:

Foreman and Proxy versions:

  • foreman-3.5.1-1.el8.noarch
  • katello-4.7.3-1.el8.noarch
  • python39-pulpcore-3.21.5-1.el8.noarch

Foreman and Proxy plugin versions:

Distribution and version:
RHEL 8.6
Other relevant data:

Did you check the other threads on remove orphans errors? E.g. Remove Orphans task fails after migration and update

1 Like