RDO tickets are now tracked in Jira https://issues.redhat.com/projects/RDO/issues/
Bug 1311662 - With RDO-Manager import instackenv.json gives just "baremetal" and does not import anything
Summary: With RDO-Manager import instackenv.json gives just "baremetal" and does not i...
Keywords:
Status: CLOSED EOL
Alias: None
Product: RDO
Classification: Community
Component: rdo-manager
Version: trunk
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
: Kilo
Assignee: Hugh Brock
QA Contact: Shai Revivo
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-02-24 17:08 UTC by Raoul Scarazzini
Modified: 2016-05-19 15:55 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-05-19 15:55:15 UTC
Embargoed:


Attachments (Terms of Use)

Description Raoul Scarazzini 2016-02-24 17:08:58 UTC
Description of problem:

While trying to complete the installation of Mitaka via RDO Manager the command:

openstack baremetal import --json ~/instackenv.json

output just "baremetal" and is not importing anything.

Looking inside verbose output I got this:

START with options: ['-vvv', 'baremetal', 'import', '--json', '/home/stack/instackenv.json']
options: Namespace(access_token_endpoint='', auth_type='', auth_url='http://192.0.2.1:5000/v2.0', cacert='', client_id='', client_secret='', cloud='', debug=False, default_domain='default', deferred_help=False, domain_id='', domain_name='', endpoint='', identity_provider='', identity_provider_url='', insecure=None, inspector_api_version='1', inspector_url=None, interface='', log_file=None, os_compute_api_version='', os_data_processing_api_version='1.1', os_identity_api_version='', os_image_api_version='1', os_network_api_version='', os_object_api_version='', os_project_id=None, os_project_name=None, os_tripleoclient_api_version='1', os_volume_api_version='', password='d63f06589eb23a6a8ad6b9c38927010ea66ff726', project_domain_id='', project_domain_name='', project_id='', project_name='admin', protocol='', region_name='', scope='', service_provider_endpoint='', timing=False, token='', trust_id='', url='', user_domain_id='', user_domain_name='', user_id='', username='admin', verbose_level=4, verify=None)
defaults: {'auth_type': 'password', 'compute_api_version': '2', 'key': None, 'database_api_version': '1.0', 'api_timeout': None, 'baremetal_api_version': '1', 'cacert': None, 'image_api_use_tasks': False, 'floating_ip_source': 'neutron', 'orchestration_api_version': '1', 'interface': None, 'network_api_version': '2', 'image_format': 'qcow2', 'object_api_version': '1', 'image_api_version': '2', 'verify': True, 'identity_api_version': '2', 'volume_api_version': '1', 'cert': None, 'secgroup_source': 'neutron', 'dns_api_version': '2', 'disable_vendor_agent': {}}
cloud cfg: {'auth_type': 'password', 'tripleoclient_api_version': '1', 'compute_api_version': '2', 'orchestration_api_version': '1', 'database_api_version': '1.0', 'data_processing_api_version': '1.1', 'inspector_api_version': '1', 'network_api_version': '2', 'image_format': 'qcow2', 'object_api_version': '1', 'image_api_version': '1', 'verify': True, 'timing': False, 'dns_api_version': '2', 'verbose_level': 4, 'region_name': '', 'api_timeout': None, 'baremetal_api_version': '1', 'auth': {'username': 'admin', 'tenant_name': 'admin', 'project_name': 'admin', 'password': 'd63f06589eb23a6a8ad6b9c38927010ea66ff726', 'auth_url': 'http://192.0.2.1:5000/v2.0'}, 'default_domain': 'default', 'image_api_use_tasks': False, 'floating_ip_source': 'neutron', 'key': None, 'cacert': None, 'deferred_help': False, 'identity_api_version': '2', 'volume_api_version': '1', 'cert': None, 'secgroup_source': 'neutron', 'debug': False, 'interface': None, 'disable_vendor_agent': {}}
compute API version 2, cmd group openstack.compute.v2
network API version 2, cmd group openstack.network.v2
image API version 1, cmd group openstack.image.v1
volume API version 1, cmd group openstack.volume.v1
identity API version 2, cmd group openstack.identity.v2
object_store API version 1, cmd group openstack.object_store.v1
data_processing API version 1.1, cmd group openstack.data_processing.v1
baremetal_introspection API version 1, cmd group openstack.baremetal_introspection.v1
tripleoclient API version 1, cmd group openstack.tripleoclient.v1
command: baremetal import -> tripleoclient.v1.baremetal.ImportBaremetal
Auth plugin password selected
auth_type: password
Using auth plugin: password
Using parameters {'username': 'admin', 'tenant_name': 'admin', 'password': 'd63f06589eb23a6a8ad6b9c38927010ea66ff726', 'project_name': 'admin', 'auth_url': 'http://192.0.2.1:5000/v2.0'}
Get auth_ref
REQ: curl -g -i -X GET http://192.0.2.1:5000/v2.0 -H "Accept: application/json" -H "User-Agent: python-openstackclient"
RESP: [200] Content-Length: 223 Content-Encoding: gzip Vary: X-Auth-Token,Accept-Encoding Server: Apache/2.4.6 (CentOS) Connection: close Date: Wed, 24 Feb 2016 17:05:34 GMT Content-Type: application/json x-openstack-request-id: req-1bf07fd9-9278-4ed4-a086-baff620d0ff7 
RESP BODY: {"version": {"status": "stable", "updated": "2014-04-17T00:00:00Z", "media-types": [{"base": "application/json", "type": "application/vnd.openstack.identity-v2.0+json"}], "id": "v2.0", "links": [{"href": "http://192.0.2.1:5000/v2.0/", "rel": "self"}, {"href": "http://docs.openstack.org/", "type": "text/html", "rel": "describedby"}]}}

Making authentication request to http://192.0.2.1:5000/v2.0/tokens
take_action(Namespace(csv=False, file_in=<open file '/home/stack/instackenv.json', mode 'r' at 0x2dccc90>, json=True, service_host=None))
baremetal
clean_up ImportBaremetal: baremetal
END return value: 1

Version-Release number of selected component (if applicable):

CentOS Linux release 7.2.1511 (Core)
instack-undercloud-3.0.1-0.20160222015108.4ac8f6e.el7.centos.noarch
openstack-tripleo-heat-templates-1.0.1-0.20160223125820.ef73827.el7.centos.noarch

How reproducible:

Always.

Steps to Reproduce:

Just follow the steps to deploy with RDO-Manager/TripleO and take a look to the import instackenv command.

Actual results:

"baremetal"

Expected results:

Output empty and nodes imported.

Additional info:

The nova logs are full of:

2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler [req-98534857-9db7-4301-8377-1d0334301c00 - - - - -] Failed to get metadata for ip: 192.0.2.10
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler Traceback (most recent call last):
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/nova/api/metadata/handler.py", line 161, in _handle_remote_ip_request
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     meta_data = self.get_metadata_by_remote_address(remote_address)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/nova/api/metadata/handler.py", line 88, in get_metadata_by_remote_address
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     data = base.get_metadata_by_address(address)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/nova/api/metadata/base.py", line 537, in get_metadata_by_address
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     fixed_ip = network.API().get_fixed_ip_by_address(ctxt, address)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/nova/network/neutronv2/api.py", line 1307, in get_fixed_ip_by_address
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     uuid_maps = self._get_instance_uuids_by_ip(context, address)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/nova/network/neutronv2/api.py", line 1205, in _get_instance_uuids_by_ip
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     data = get_client(context).list_ports(**search_opts)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/nova/network/neutronv2/api.py", line 237, in get_client
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     auth_token = _ADMIN_AUTH.get_token(_SESSION)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/base.py", line 200, in get_token
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     return self.get_access(session).auth_token
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/base.py", line 240, in get_access
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     self.auth_ref = self.get_auth_ref(session)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/v3/base.py", line 190, in get_auth_ref
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     authenticated=False, log=False, **rkwargs)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 501, in post
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     return self.request(url, 'POST', **kwargs)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 337, in inner
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     return func(*args, **kwargs)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler   File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 401, in request
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler     raise exceptions.from_response(resp, method, url)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler NotFound: The resource could not be found. (HTTP 404) (Request-ID: req-1ed5b7d8-8394-4184-b5f7-056171735814)
2016-02-24 17:06:23.454 29191 ERROR nova.api.metadata.handler

Comment 1 Raoul Scarazzini 2016-03-15 13:58:54 UTC
Adding the sosreport [1] coming from a system with the exact same problem.

[1] http://file.rdu.redhat.com/~rscarazz/BZ1311662/sosreport-mrg-06.mpc.lab.eng.bos.redhat.com.1311662-20160315095329.tar.xz

Comment 2 Raoul Scarazzini 2016-03-16 10:48:23 UTC
So this problem seems to be related to a version issue (with the package python-ironicclient), in fact while creating repos via tripleo.sh --repo-setup (see https://github.com/openstack-infra/tripleo-ci) the problem is not present.

In any case I think the message should be somehow changed in something more helpful for the user.

Comment 4 Chandan Kumar 2016-05-19 15:55:15 UTC
This bug is against a Version which has reached End of Life.
If it's still present in supported release (http://releases.openstack.org), please update Version and reopen.


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