Bug 1402497 - rhel-osp-director: Deploying OSP10 with satellite, the OC nodes aren't registered.
Summary: rhel-osp-director: Deploying OSP10 with satellite, the OC nodes aren't regist...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: python-tripleoclient
Version: 10.0 (Newton)
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: async
: 10.0 (Newton)
Assignee: Brad P. Crochet
QA Contact: Omri Hochman
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-12-07 16:44 UTC by Alexander Chuzhoy
Modified: 2022-08-10 09:52 UTC (History)
20 users (show)

Fixed In Version: python-tripleoclient-5.4.0-3.el7ost
Doc Type: Deprecated Functionality
Doc Text:
Certain CLI arguments are considered deprecated and should not be used. The update will allow you to use the CLI args, but there is still a need to specify at the least an environment file to set the `sat_repo`. You can use an `env` file to work around the issue, before running the overcloud command: 1. cp -r /usr/share/openstack-tripleo-heat-templates/extraconfig/pre_deploy/rhel-registration . 2. Edit the rhel-registration/environment-rhel-registration.yaml and set the rhel_reg_org, rhel_reg_activation_key, rhel_reg_method, rhel_reg_sat_repo and rhel_reg_sat_url according to your environment. 3. Run the deployment command with -e rhel-registration/rhel-registration-resource-registry.yaml -e rhel-registration/environment-rhel-registration.yaml This workaround has been checked for both Red Hat Satellite 5 and 6, with repos present on the overcloud nodes upon successful deployment.
Clone Of:
Environment:
Last Closed: 2016-12-21 16:52:28 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
output from heat resource-list -n5 overcloud (281.53 KB, text/plain)
2016-12-07 18:00 UTC, Alexander Chuzhoy
no flags Details
output from "openstack stack environment show overcloud" (70.88 KB, text/plain)
2016-12-07 18:19 UTC, Alexander Chuzhoy
no flags Details
deployment-show (3.65 KB, text/plain)
2016-12-07 18:36 UTC, Alexander Chuzhoy
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Launchpad 1648236 0 None None None 2016-12-07 21:57:23 UTC
OpenStack gerrit 408323 0 None None None 2016-12-07 21:54:36 UTC
OpenStack gerrit 408772 0 None None None 2016-12-08 18:48:05 UTC
Red Hat Issue Tracker OSP-7767 0 None None None 2022-08-10 09:52:34 UTC
Red Hat Knowledge Base (Solution) 2300461 0 None None None 2017-01-14 21:32:46 UTC
Red Hat Product Errata RHBA-2016:2978 0 normal SHIPPED_LIVE Red Hat OpenStack Platform 10 Bug Fix Advisory 2016-12-21 21:36:10 UTC

Description Alexander Chuzhoy 2016-12-07 16:44:25 UTC
rhel-osp-director: Deploying OSP10 with sat5, the OC nodes aren't registered.

Environment:
instack-undercloud-5.1.0-4.el7ost.noarch
openstack-tripleo-heat-templates-5.1.0-7.el7ost.noarch
openstack-puppet-modules-9.3.0-1.el7ost.noarch

Steps to reproduce:
Deploy overcloud with this command:
openstack overcloud deploy --templates --control-scale 3 --compute-scale 2 --neutron-network-type vxlan --neutron-tunnel-types vxlan --ntp-server clock.redhat.com --timeout 90 -e /usr/share/openstack-tripleo-heat-templates/environments/storage-environment.yaml -e /usr/share/openstack-tripleo-heat-templates/environments/network-isolation.yaml -e network-environment.yaml --rhel-reg --reg-method satellite --reg-sat-url <url> --reg-org <id> --reg-activation-key <key> --reg-force --ceph-storage-scale 1


After the deployment completes successfully, login to any OC node and check the available repo:
Result:
[heat-admin@overcloud-controller-0 ~]$ sudo yum repolist
Loaded plugins: product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
repolist: 0


Expected result:
List of repos provided by sat5.

Comment 1 James Slagle 2016-12-07 16:47:50 UTC
can you attach output of:
openstack stack resource list -n 5 overcloud

Comment 2 Alexander Chuzhoy 2016-12-07 18:00:55 UTC
Created attachment 1229187 [details]
output from heat resource-list -n5 overcloud

Comment 3 Alexander Chuzhoy 2016-12-07 18:19:33 UTC
Created attachment 1229188 [details]
output from "openstack stack environment show overcloud"

Comment 4 Alexander Chuzhoy 2016-12-07 18:36:14 UTC
Created attachment 1229202 [details]
deployment-show

Comment 5 James Slagle 2016-12-07 18:39:47 UTC
the environment show indicates that all the rhel_reg_* parameters are empty or their default values. that seems to indicate that the cli did not update the arguments to the plan

Comment 6 Alexander Chuzhoy 2016-12-07 21:03:24 UTC
Same problem with sat6 deployment.

Comment 7 Brad P. Crochet 2016-12-07 21:11:54 UTC
So, the parameters are being recognized by the cli, but the values aren't properly making it into the mistral environment. Further investigation required.

Comment 8 Alexander Chuzhoy 2016-12-07 23:04:54 UTC
The issue can be worked around with using env files:


Before running the overcloud command:

1. cp -r /usr/share/openstack-tripleo-heat-templates/extraconfig/pre_deploy/rhel-registration  . 

2. Edit the hel-registration/environment-rhel-registration.yaml and set the   rhel_reg_org, rhel_reg_activation_key, rhel_reg_method, rhel_reg_sat_repo and rhel_reg_sat_url according to your environment.

Run the deployment command with -e rhel-registration/rhel-registration-resource-registry.yaml -e rhel-registration/environment-rhel-registration.yaml

Checked that it works for both sat6 and sat5 - saw repos on overcloud nodes upon successful deployment.

Comment 19 Omri Hochman 2016-12-13 15:15:04 UTC
we need to check if we're relying on having the Satellite parameters to be taken them from the original $DEPLOY command ? or we can use the .yaml file in major-upgrade scenario ? 

otherwise it could be that major-upgrade osp9 to osp10 with SAT parameters will be blocked according this bug

Comment 20 Sofer Athlan-Guyot 2016-12-13 16:49:40 UTC
Reading the code, as OSP9 installation will have registered the
parameters, if no change is required for:

   --reg-method,
   --reg-org,
   --reg-force,
   --reg-sat-url,
   --reg-activation-key

to upgrade to OSP10, then the heat parameters should already be in
place and it shouldn't be needed to pass them again.

On the other side tarting the upgrade using a template for the reg parameters should be working. 

This has to be tested.  But I don't have any access to any satellite
platform.

(I don't know how to clear my needinfo, without clearing the other, so I don't clear anything)

Comment 22 Jaromir Coufal 2016-12-13 19:36:36 UTC
Omri, Sofer provided some info, could you verify within QE team?

Comment 24 Omri Hochman 2016-12-14 17:50:28 UTC
(In reply to Jaromir Coufal from comment #22)
> Omri, Sofer provided some info, could you verify within QE team?

I guess we would need someone to run clean deployment of osp9 using SAT5/6 register and then continue to major-upgrade of osp10 , and see what happens . 

Adding need-Info on Amit - to see who can check this from life-cycle side.

Comment 26 Alexander Chuzhoy 2016-12-16 16:48:15 UTC
Failed to verify:
Environment:
python-tripleoclient-5.4.0-3.el7ost.noarch


Running the deployment with args fails with:
 resources[1]: Property error: resources.NodeExtraConfig.properties: Property rhel_reg_auto_attach not assigned

Comment 27 Brad P. Crochet 2016-12-16 17:59:33 UTC
For clarification. What was fixed in the above patch was to remove the default registration environment file. The contents of the environment file were overriding what was being passed on the command line (by design). The client was automatically including that environment file. The fix was to stop that behavior. The result is that the CLI args that exist work again, but they are no longer enough to register a system with RHN/Satellite. Therefore, it is recommended that an operator should use the environment file exclusively, and consider the cli args fully deprecated. This occurred as parameters were added to the RHN/Satellite registration template, and those parameters were not reflected in the cli.

Comment 28 Scott Lewis 2016-12-19 15:57:59 UTC
(In reply to Brad P. Crochet from comment #27)
> For clarification. What was fixed in the above patch was to remove the
> default registration environment file. The contents of the environment file
> were overriding what was being passed on the command line (by design). The
> client was automatically including that environment file. The fix was to
> stop that behavior. The result is that the CLI args that exist work again,
> but they are no longer enough to register a system with RHN/Satellite.
> Therefore, it is recommended that an operator should use the environment
> file exclusively, and consider the cli args fully deprecated. This occurred
> as parameters were added to the RHN/Satellite registration template, and
> those parameters were not reflected in the cli.

Sasha, does this clarification help? Can we switch this back to ON-QA or VER?

Comment 29 Mike Burns 2016-12-20 14:13:42 UTC
Based on comment 27, I would say this should be ON_QA.  Verification should be that with a valid environment file, we can register with command line options and that with options just in an environment file, it will work as well.

As noted in comment 27, deployment with *just* parameters will not work.  That can be tracked in a separate bug if PM deems it worth tracking (otherwise a separate bug for updating docs should be done if not already filed)

Comment 33 errata-xmlrpc 2016-12-21 16:52:28 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-2016-2978.html

Comment 34 Amit Ugol 2018-05-02 10:50:26 UTC
closed, no need for needinfo.


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