Content_source: ["with given ID not found"]


I’m new with Foreman and I try to Install and subscribe RH8.9.
Subscription: Manifest imported
Red Hat Repositories: Added
Host Group: Content Source configured with the foreman-proxy
Host: Content Source configured automatically with the host group, so it’s the foreman-proxy

I can install RH8.9, but I have a problem with the subscription. After the installation the content source removed automatically and need to choose the proxy again if I want to reinstall. I think the problem is linked when I check the logs. Maybe a bug? Impossible for me to subscribe after the installation (tried with subscription-manager register and curl command).

subscription-manager register" --org=‘dieu’ --activationkey=‘dieukey’
Validation failed: Content source with given ID not found (HTTP error code 422: Unprocessable Entity)

Foreman and Proxy versions:
System Information
Version 3.9.1 © 2009-2024 Paul Kelly and Ohad Levy

Foreman and Proxy plugin versions:

  • katello-4.11.0-1.el8.noarch
  • katello-certs-tools-2.9.0-2.el8.noarch
  • katello-client-bootstrap-1.7.9-2.el8.noarch
  • katello-common-4.11.0-1.el8.noarch
  • katello-debug-4.11.0-1.el8.noarch
  • katello-repos-4.11.0-1.el8.noarch
  • katello-selinux-5.0.2-1.el8.noarch

** Logs **
2024-05-02T13:01:01 [I|app|XXXXXX] generating new uuid
2024-05-02T13:01:01 [E|kat|XXXXXX] ActiveRecord::RecordInvalid
2024-05-02T13:01:01 [E|kat|XXXXXX] content_source: [“with given ID not found”]


Hi @volkanos

Can you please post the error traceback?

Was this host previously registered? Are you able to delete the host record from Foreman and try again?


See in production.log error:
2024-05-06T09:13:56 [I|aud|5a3175ef] Katello::Host::ContentFacet (66) update event on content_source_id 2, 1
2024-05-06T09:13:56 [I|app|5a3175ef] generating new uuid
2024-05-06T09:13:56 [E|kat|5a3175ef] ActiveRecord::RecordInvalid
2024-05-06T09:13:56 [E|kat|5a3175ef] content_source: [“with given ID not found”]

Tried 2 new hosts and always get the same error.


No stack traces in the production log other than this error ?

Wonder if its a permissions issue


subscription-manager register" --org=‘dieu’ --username --password

Assuming user is an admin.


Sorry for the delay, but I have no more information in the logs.
I tried the command and asked for the environment, after I put the input. Same error:
Validation failed: Content source with given ID not found (HTTP error code 422: Unprocessable Entity)