Bug 1164032 - RH Updates: Satellite 6 registration
Summary: RH Updates: Satellite 6 registration
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Appliance
Version: 5.3.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: GA
: 5.3.3
Assignee: Brandon Dunne
QA Contact: Jan Krocil
URL:
Whiteboard:
Depends On: 1163465
Blocks: 1139277
TreeView+ depends on / blocked
 
Reported: 2014-11-14 00:08 UTC by Dave Johnson
Modified: 2015-03-23 16:21 UTC (History)
9 users (show)

Fixed In Version: 5.3.3
Doc Type: Bug Fix
Doc Text:
The appliance could not register to the Satellite 6 server. Updated Satellite 6 certificate RPM file name. Also allowed specifying an environment when registering to SubscriptionManager. And, setting default environment when registering to Satellite 6. These changes have now fixed the issue and the appliance successfully registers to the Satellite 6 server.
Clone Of: 1163465
Environment:
bz_monday 020215
Last Closed: 2015-02-25 16:11:34 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Registration error log (9.80 KB, text/plain)
2015-02-16 09:30 UTC, Jan Krocil
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:0261 0 normal SHIPPED_LIVE cfme (5.3.3) bug fix and enhancement update 2015-02-25 21:09:28 UTC

Comment 6 CFME Bot 2014-12-16 21:05:22 UTC
New commit detected on linux_admin/master:
https://github.com/ManageIQ/linux_admin/commit/d22cf30fca2e160419a29b16216f89f5a00194d6

commit d22cf30fca2e160419a29b16216f89f5a00194d6
Author:     Brandon Dunne <bdunne>
AuthorDate: Tue Dec 16 15:14:49 2014 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Tue Dec 16 15:14:49 2014 -0500

    Allow specifying an environment when registering to SubscriptionManager
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 lib/linux_admin/registration_system/subscription_manager.rb | 3 ++-
 spec/subscription_manager_spec.rb                           | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

Comment 7 CFME Bot 2014-12-17 20:46:06 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/255b8254ae500af7e88665b89b308601c714dd19

commit 255b8254ae500af7e88665b89b308601c714dd19
Author:     Brandon Dunne <bdunne>
AuthorDate: Wed Dec 17 12:59:16 2014 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Wed Dec 17 12:59:16 2014 -0500

    Set default environment when registering to Satellite 6
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 lib/Gemfile                                        | 46 +++++++++++-----------
 vmdb/app/models/miq_server/update_management.rb    |  6 ++-
 .../models/miq_server/update_management_spec.rb    | 11 ++++--
 3 files changed, 35 insertions(+), 28 deletions(-)

Comment 8 CFME Bot 2014-12-17 21:26:04 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=4c7f4ce98a0a2d7f67a3b477272ed2a49b77af11

commit 4c7f4ce98a0a2d7f67a3b477272ed2a49b77af11
Author:     Brandon Dunne <bdunne>
AuthorDate: Wed Dec 17 12:59:16 2014 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Wed Dec 17 16:21:54 2014 -0500

    Set default environment when registering to Satellite 6
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 lib/Gemfile                                        | 42 +++++++++++-----------
 vmdb/app/models/miq_server/update_management.rb    |  6 +++-
 .../models/miq_server/update_management_spec.rb    | 11 +++---
 3 files changed, 33 insertions(+), 26 deletions(-)

Comment 9 Jan Krocil 2015-01-09 15:33:54 UTC
Still fails in 5.3.2.6 (the last commit is present and linux_admin version is 0.9.4-1).

[----] E, [2015-01-09T14:55:39.487311 #2424:115803c] ERROR -- : MIQ(MiqQueue.deliver)    Message id: [1635], Error: [subscription-manager register exit code: 255]
[----] E, [2015-01-09T14:55:39.487887 #2424:115803c] ERROR -- : [AwesomeSpawn::CommandResultError]: subscription-manager register exit code: 255  Method:[rescue in deliver]
[----] E, [2015-01-09T14:55:39.488106 #2424:115803c] ERROR -- : /opt/rh/ruby193/root/usr/share/gems/gems/awesome_spawn-1.2.1/lib/awesome_spawn.rb:97:in `run!'
/opt/rh/ruby193/root/usr/share/gems/gems/linux_admin-0.9.4/lib/linux_admin/common.rb:14:in `run!'
/opt/rh/ruby193/root/usr/share/gems/gems/linux_admin-0.9.4/lib/linux_admin/registration_system/subscription_manager.rb:6:in `run!'
/opt/rh/ruby193/root/usr/share/gems/gems/linux_admin-0.9.4/lib/linux_admin/registration_system/subscription_manager.rb:52:in `register'
/opt/rh/ruby193/root/usr/share/gems/gems/linux_admin-0.9.4/lib/linux_admin/registration_system.rb:12:in `method_missing'
/var/www/miq/vmdb/app/models/miq_server/update_management.rb:83:in `register'
/var/www/miq/vmdb/app/models/miq_server/update_management.rb:58:in `attempt_registration'
/var/www/miq/vmdb/app/models/miq_server/update_management.rb:52:in `update_registration_status'
/var/www/miq/vmdb/app/models/miq_queue.rb:361:in `block in deliver'
/opt/rh/ruby193/root/usr/share/ruby/timeout.rb:69:in `timeout'
/var/www/miq/vmdb/app/models/miq_queue.rb:357:in `deliver'
/var/www/miq/vmdb/lib/workers/queue_worker_base.rb:107:in `deliver_queue_message'
/var/www/miq/vmdb/lib/workers/queue_worker_base.rb:135:in `deliver_message'
/var/www/miq/vmdb/lib/workers/queue_worker_base.rb:152:in `block in do_work'
/var/www/miq/vmdb/lib/workers/queue_worker_base.rb:146:in `loop'
/var/www/miq/vmdb/lib/workers/queue_worker_base.rb:146:in `do_work'
/var/www/miq/vmdb/lib/workers/worker_base.rb:317:in `block in do_work_loop'
/var/www/miq/vmdb/lib/workers/worker_base.rb:314:in `loop'
/var/www/miq/vmdb/lib/workers/worker_base.rb:314:in `do_work_loop'
/var/www/miq/vmdb/lib/workers/worker_base.rb:135:in `run'
/var/www/miq/vmdb/lib/workers/worker_base.rb:123:in `start'
/var/www/miq/vmdb/lib/workers/worker_base.rb:23:in `start_worker'
/var/www/miq/vmdb/lib/workers/bin/worker.rb:5:in `<top (required)>'
/opt/rh/ruby193/root/usr/share/gems/gems/railties-3.2.17/lib/rails/commands/runner.rb:52:in `eval'
/opt/rh/ruby193/root/usr/share/gems/gems/railties-3.2.17/lib/rails/commands/runner.rb:52:in `<top (required)>'
/opt/rh/ruby193/root/usr/share/gems/gems/railties-3.2.17/lib/rails/commands.rb:64:in `require'
/opt/rh/ruby193/root/usr/share/gems/gems/railties-3.2.17/lib/rails/commands.rb:64:in `<top (required)>'
script/rails:6:in `require'
script/rails:6:in `<main>'
[----] I, [2015-01-09T14:55:39.488616 #2424:115803c]  INFO -- : MIQ(MiqQueue.delivered)  Message id: [1635], State: [error], Delivered in [7.663450657] seconds

Comment 10 Jan Krocil 2015-01-09 15:53:07 UTC
Moving back to ON_DEV...

Comment 12 CFME Bot 2015-02-02 15:00:57 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/8cd9e05b203ea7b5e6e6f1cf385e46a19fa937bf

commit 8cd9e05b203ea7b5e6e6f1cf385e46a19fa937bf
Author:     Brandon Dunne <bdunne>
AuthorDate: Thu Jan 29 16:46:16 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Thu Jan 29 16:46:45 2015 -0500

    Send AwesomeSpawn logging to evm.log to allow better failure logging
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 lib/Gemfile                                     | 2 +-
 vmdb/app/models/miq_server/update_management.rb | 1 -
 vmdb/lib/vmdb/logging.rb                        | 8 ++++++++
 3 files changed, 9 insertions(+), 2 deletions(-)

Comment 13 Brandon Dunne 2015-02-02 23:56:45 UTC
With the above changes copied to an appliance, retesting registration points out that the failure is due to sending the organization "name" to the gem rather than the organization "key".  Further work is required to present the proper selection and store it in the database to later be passed along to the gem.

Comment 14 CFME Bot 2015-02-09 15:00:50 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/ae5a5b3be3e9ecee6ed2995a51500f5715cb6328

commit ae5a5b3be3e9ecee6ed2995a51500f5715cb6328
Author:     Brandon Dunne <bdunne>
AuthorDate: Fri Feb 6 09:38:20 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Fri Feb 6 18:15:17 2015 -0500

    Pass the key along with the name to the UI
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/models/registration_system.rb       | 3 ++-
 vmdb/spec/models/registration_system_spec.rb | 4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)

Comment 15 CFME Bot 2015-02-09 15:00:54 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/5a78871ddc0ce617ddb660504b4a34fcacb3c47d

commit 5a78871ddc0ce617ddb660504b4a34fcacb3c47d
Author:     Brandon Dunne <bdunne>
AuthorDate: Fri Feb 6 09:38:53 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Fri Feb 6 18:15:17 2015 -0500

    Add registration_organization_display_name to MiqDatabase
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/models/miq_database.rb | 4 ++++
 1 file changed, 4 insertions(+)

Comment 16 CFME Bot 2015-02-09 15:00:57 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/79ebbfdae0fd3b788708f90e51463450d2b27c52

commit 79ebbfdae0fd3b788708f90e51463450d2b27c52
Author:     Brandon Dunne <bdunne>
AuthorDate: Fri Feb 6 14:09:16 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Fri Feb 6 18:15:17 2015 -0500

    Migrate MiqDatabase#registration_organization_display_name out of Reserves
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/models/miq_database.rb                    |  4 --
 ...on_organization_display_name_out_of_reserves.rb | 27 +++++++++++++
 ...on_organization_display_name_out_of_reserves.rb | 46 ++++++++++++++++++++++
 3 files changed, 73 insertions(+), 4 deletions(-)
 create mode 100644 vmdb/db/migrate/20150206150955_migrate_miq_database_registration_organization_display_name_out_of_reserves.rb
 create mode 100644 vmdb/spec/migrations/20150206150955_migrate_miq_database_registration_organization_display_name_out_of_reserves.rb

Comment 17 CFME Bot 2015-02-09 15:01:00 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/9413dfd65c3159d1cbd0ae3529ea9bc917334357

commit 9413dfd65c3159d1cbd0ae3529ea9bc917334357
Author:     Harpreet Kataria <hkataria>
AuthorDate: Fri Feb 6 16:06:44 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Fri Feb 6 18:15:17 2015 -0500

    Adjusted UI code to expect organization to be a hash
    
    Adjusted UI code to expect organization to be a hash, save selected value in registration_organization and the display name in registration_organization_display_name columns of database record.
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/controllers/ops_controller/settings/rhn.rb | 3 ++-
 vmdb/app/views/ops/_settings_rhn_edit_tab.haml      | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

Comment 18 CFME Bot 2015-02-09 15:46:18 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=85492ace8416805cd361aff50746ca9337604823

commit 85492ace8416805cd361aff50746ca9337604823
Author:     Brandon Dunne <bdunne>
AuthorDate: Fri Feb 6 09:38:20 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Mon Feb 9 10:32:29 2015 -0500

    Pass the key along with the name to the UI
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/models/registration_system.rb       | 3 ++-
 vmdb/spec/models/registration_system_spec.rb | 4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)

Comment 19 CFME Bot 2015-02-09 15:46:21 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=1979b3849ffcb11fbad9ea651c406f916bfa3db9

commit 1979b3849ffcb11fbad9ea651c406f916bfa3db9
Author:     Brandon Dunne <bdunne>
AuthorDate: Fri Feb 6 09:38:53 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Mon Feb 9 10:35:12 2015 -0500

    Add registration_organization_display_name to MiqDatabase
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/models/miq_database.rb | 4 ++++
 1 file changed, 4 insertions(+)

Comment 20 CFME Bot 2015-02-09 15:46:24 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=0ebfb97d655de30032df710b19564cedccc54bed

commit 0ebfb97d655de30032df710b19564cedccc54bed
Author:     Harpreet Kataria <hkataria>
AuthorDate: Fri Feb 6 16:06:44 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Mon Feb 9 10:43:37 2015 -0500

    Adjusted UI code to expect organization to be a hash
    
    Adjusted UI code to expect organization to be a hash, save selected value in registration_organization and the display name in registration_organization_display_name columns of database record.
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/controllers/ops_controller/settings/rhn.rb | 3 ++-
 vmdb/app/views/ops/_settings_rhn_edit_tab.haml      | 4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)

Comment 22 Jan Krocil 2015-02-16 09:29:04 UTC
Sat6 registration works OK now, but this set of commits broke Sat5 and RHSM registration, so I can't verify this.

Moving back to ON_DEV.

(production.log with the issue will be attached below)

Comment 23 Jan Krocil 2015-02-16 09:30:07 UTC
Created attachment 992088 [details]
Registration error log

Comment 24 CFME Bot 2015-02-16 16:01:02 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/fe3d2205f4b69d3eab56df94d66fc8ed2baddda3

commit fe3d2205f4b69d3eab56df94d66fc8ed2baddda3
Author:     Brandon Dunne <bdunne>
AuthorDate: Mon Feb 16 09:40:43 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Mon Feb 16 09:44:54 2015 -0500

    @edit[:organizations] is nil for SAT5 and RHSM Hosted
    
    [skip ci]
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/controllers/ops_controller/settings/rhn.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 25 CFME Bot 2015-02-16 16:05:52 UTC
New commit detected on cfme/5.3.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=eaf6f374cb8d79cda43adcbff0dc3101f62642dd

commit eaf6f374cb8d79cda43adcbff0dc3101f62642dd
Author:     Brandon Dunne <bdunne>
AuthorDate: Mon Feb 16 09:40:43 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Mon Feb 16 11:03:08 2015 -0500

    @edit[:organizations] is nil for SAT5 and RHSM Hosted
    
    [skip ci]
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/controllers/ops_controller/settings/rhn.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 26 CFME Bot 2015-02-16 16:15:37 UTC
New commit detected on cfme/5.3.3:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=8ffb1dfc11d341bd28f59512749d139369a5c32d

commit 8ffb1dfc11d341bd28f59512749d139369a5c32d
Author:     Brandon Dunne <bdunne>
AuthorDate: Mon Feb 16 09:40:43 2015 -0500
Commit:     Brandon Dunne <bdunne>
CommitDate: Mon Feb 16 11:04:44 2015 -0500

    @edit[:organizations] is nil for SAT5 and RHSM Hosted
    
    [skip ci]
    https://bugzilla.redhat.com/show_bug.cgi?id=1164032

 vmdb/app/controllers/ops_controller/settings/rhn.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 27 Jan Krocil 2015-02-23 15:28:57 UTC
Verified - fixed in 5.3.3.2 (5.3.3.2.20150217120931_a465215).

Registration to Satellite 6 now works and the issues with Satellite 5 and RHSM introduced by the previous version of this fix have been amended as well.

Comment 29 errata-xmlrpc 2015-02-25 16:11:34 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-0261.html


Note You need to log in before you can comment on or make changes to this bug.