Project

General

Profile

Bug #31645

Feature #30440: Simple & automatic host registration WF

Global registration fails with Validation failed: Name can't be blank

Added by Leos Stejskal about 2 months ago. Updated about 2 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Host registration
Target version:
-
Difficulty:
Triaged:
No
Bugzilla link:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1900694

Description of problem:

Attempting to register host via global registration fails on hosts

ERROR: Validation failed: Name can't be blank, Name hostname can contain only lowercase letters, numbers, dashes and dots according to RFC921, RFC952 and RFC1123

The curl command:

curl -k -X GET "https://myhg.redhat.com:9090/register?host_group_id=1&location_id=2&operatingsystem_id=1&organization_id=1&setup_insights=true&smart_proxy=1&activation_key=mykey" -H 'Authorization: Bearer ey...VvSI' | bash

Production log excerpt:

2020-11-23T15:21:20 [I|app|4851439e] Started POST "/register?url=https%3A%2F%2Fmyhostname.redhat.com%3A9090" for 2620:52:0:2598:224:e8ff:fe4a:b245 at 2020-11-23 15:21:20 +0100
2020-11-23T15:21:20 [I|app|4851439e] Processing by Api::V2::RegistrationController#host as HTML
2020-11-23T15:21:20 [I|app|4851439e] Parameters: {"host"=>{"organization_id"=>"1", "location_id"=>"2"}, "setup_insights"=>"true", "url"=>"https://myhostname.redhat.com:9090"}
2020-11-23T15:21:20 [I|app|4851439e] Authorized user admin(Admin User)
2020-11-23T15:21:20 [D|app|4851439e] Post-login processing for admin
2020-11-23T15:21:20 [D|tax|4851439e] Current location set to none
2020-11-23T15:21:20 [D|tax|4851439e] Current organization set to none
2020-11-23T15:21:20 [D|tax|4851439e] Current location set to none
2020-11-23T15:21:20 [D|tax|4851439e] Current organization set to none
2020-11-23T15:21:20 [D|app|4851439e] Unpermitted parameters: :setup_insights, :url
2020-11-23T15:21:20 [D|app|4851439e] Unpermitted parameters: :setup_insights, :url
2020-11-23T15:21:20 [D|app|4851439e] Unpermitted parameters: :setup_insights, :url
2020-11-23T15:21:20 [W|app|4851439e] Not queueing Host::Managed: ["Name can't be blank", "Name hostname can contain only lowercase letters, numbers, dashes and dots according to RFC921, RFC952 and RFC1123"]
2020-11-23T15:21:20 [W|app|4851439e] Not queueing Host::Managed: ["Name can't be blank", "Name hostname can contain only lowercase letters, numbers, dashes and dots according to RFC921, RFC952 and RFC1123"]
2020-11-23T15:21:20 [W|app|4851439e] Not queueing Host::Managed: ["Name can't be blank", "Name hostname can contain only lowercase letters, numbers, dashes and dots according to RFC921, RFC952 and RFC1123"]
2020-11-23T15:21:20 [W|app|4851439e] Not queueing Discovery reboot: Name can't be blank and Name hostname can contain only lowercase letters, numbers, dashes and dots according to RFC921, RFC952 and RFC1123
2020-11-23T15:21:20 [I|app|4851439e] Rendering text template
2020-11-23T15:21:20 [I|app|4851439e] Rendered text template (Duration: 0.0ms | Allocations: 2)
2020-11-23T15:21:20 [I|app|4851439e] Completed 422 Unprocessable Entity in 71ms (Views: 0.4ms | ActiveRecord: 43.4ms | Allocations: 18883)

Version-Release number of selected component (if applicable):
Satellite 6.9 snap 2

How reproducible:
always

Associated revisions

Revision 3a78baa8 (diff)
Added by Leos Stejskal about 2 months ago

Fixes #31645 - Missing host UUID in global registration template (#8252)

Missing UUID for RHEL & CentOS systems caused issues during
registration through the smart proxy.

History

#1 Updated by Leos Stejskal about 2 months ago

  • Parent task set to #30440
  • Assignee set to Leos Stejskal
  • Category changed from Inventory to Host registration

#2 Updated by The Foreman Bot about 2 months ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/8252 added

#3 Updated by The Foreman Bot about 2 months ago

  • Fixed in Releases 2.4.0 added

#4 Updated by Leos Stejskal about 2 months ago

  • Status changed from Ready For Testing to Closed

#5 Updated by The Foreman Bot about 2 months ago

  • Pull request https://github.com/theforeman/foreman/pull/8253 added

#6 Updated by Leos Stejskal about 2 months ago

  • Found in Releases 2.3.2 added
  • Fixed in Releases 2.3.2 added
  • Fixed in Releases deleted (2.4.0)

#7 Updated by Tomer Brisker about 2 months ago

  • Fixed in Releases 2.4.0 added

For the record - please set target release and not fixed in release if you want something to be cherry-picked to stable branch.

Also available in: Atom PDF