Red Hat Satellite Client Registration failing with Couldn't Find Host error.
Environment
- Red Hat Satellite 6
Issue
-
While trying to register the client systems with
Red Hat Satellitefails with following errors:Katello::Resources::Candlepin::Consumer: 404 Resource Not Found {"displayMessage":"Consumer with id a28cd901-5a42-45bc-92c0-709ccc0b6964 could not be found.","requestUuid":"d6751a00-c923-4603-8995-f7be29df8e2a"} (DELETE /candlepin/consumers/a28cd901-5a42-45bc-92c0-709ccc0b6964) -
Manualy registering using
Subscription-managerfails with the error:# subscription-manager register --org="Org_Name" --activationkey="Activation_Key_Name" --force Consumer with id a28cd901-5a42-45bc-92c0-709ccc0b6964 could not be found.
Resolution
-
On the Satellite Server execute the below commands to obtain the ID of the client system and then remove the old entry completely from the satellite server.
-
The
ID of the client systemwhich is present on the satellite can be obtained using the following commands.:# su - postgres -c "psql foreman" # select id,name from hosts where name = 'FQDN of ClientVM'; # exit -
After obtaining the ID of the client system, use the below commands to clean the old entry from the satellite server.
[NOTE: Please take the backup/snapshot of the satellite server. ]
# foreman-rake console # User.current = User.find_by_login('admin') # Host.find(ID).content_facet.destroy! =========>> Please mention the ID that you have got from the above commands. # Host.find(ID).subscription_facet.destroy! # Host.find(ID).destroy -
After the execution of the above steps try to re-register the system and if the still persists please contact This content is not included.Red Hat Technical Support.
For more KB articles/solutions related to Red Hat Satellite 6.x Client Subscription Issues, please refer to the Red Hat Satellite Consolidated Troubleshooting Article for Red Hat Satellite 6.x Client Subscription Issues
Root Cause
- Improper registration of the client system leads to such issues.
- It can be possible that the old entries of the client systems are present in the satellite database, due to which such issues occur.
Diagnostic Steps
- While logging in foreman-rake following error will be recieved:
irb(main):001:0> User.current = User.first
#<User id: 22, login: "test", firstname: "", lastname: "", mail: "", admin: false, last_login_on: nil, auth_source_id: 1, created_at: "2017-08-31 09:37:01", updated_at: "2017-08-31 09:37:01", password_hash: "50aebb01d297398c191398e02a8435371d8c04ff", password_salt: "254373ef27e686955d38e638c7ccc8c0b2475b8d", locale: nil, avatar_hash: nil, default_organization_id: nil, default_loca
tion_id: nil, lower_login: "test", mail_enabled: true, timezone: "", description: nil>
User.current = User.first ===> This command should log into satellite with any user but should have admin:true.
<User id: 22, login: "test", firstname: "", lastname: "", mail: "", admin: false, =====================>>> This should be an Admin user.
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.