I have tempest tests failing for ec2-api functionality with the same error string using python2-openstackclient.noarch 3.15.0-0.20180402052711.67edb39.el7ost botocore.exceptions.ClientError: An error occurred (AttributeError) when calling the AssociateAddress operation (reached max retries: 4): Unknown error occurred. +++ This bug was initially created as a clone of Bug #1612360 +++ Description of problem: When trying to attach a floating ip to an instance, there is an AttributeError Upstream bug: https://bugs.launchpad.net/python-novaclient/+bug/1743964 Version-Release number of selected component (if applicable): python2-openstackclient-3.14.1-1.el7ost.noarch How reproducible: Always Steps to Reproduce: 1. Deploy rhos-13 and launch a VM (overcloud) [stack@undercloud-0 ~]$ openstack server list +--------------------------------------+------------+--------+-----------------------+--------+---------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+------------+--------+-----------------------+--------+---------+ | 7b45b8ff-221d-4e28-abd7-a3b2f6ec331d | test-17719 | ACTIVE | private=192.168.100.6 | cirros | m1.tiny | +--------------------------------------+------------+--------+-----------------------+--------+---------+ 2. Attach a floating ip to the VM (overcloud) [stack@undercloud-0 ~]$ openstack server add floating ip test-17719 10.0.0.221 add_floating_ip Actual results: (overcloud) [stack@undercloud-0 ~]$ openstack server add floating ip test-17719 10.0.0.221 --debug START with options: [u'server', u'add', u'floating', u'ip', u'test-17719', u'10.0.0.221', u'--debug'] options: Namespace(access_key='', access_secret='***', access_token='***', access_token_endpoint='', access_token_type='', aodh_endpoint='', application_credential_id='', application_credential_name='', application_credential_secret='***', auth_type='password', auth_url='http://10.0.0.103:5000//v3', cacert=None, cert='', client_id='', client_secret='***', cloud='', code='', consumer_key='', consumer_secret='***', debug=True, default_domain='default', default_domain_id='', default_domain_name='', deferred_help=False, discovery_endpoint='', domain_id='', domain_name='', endpoint='', identity_provider='', identity_provider_url='', insecure=None, inspector_api_version='1', inspector_url=None, interface='', key='', log_file=None, openid_scope='', os_alarming_api_version='2', os_baremetal_api_version='1.37', os_beta_command=False, os_compute_api_version='', os_container_infra_api_version='1', os_data_processing_api_version='1.1', os_data_processing_url='', os_database_api_version='1', os_dns_api_version='2', os_identity_api_version='3', os_image_api_version='2', os_key_manager_api_version='1', os_loadbalancer_api_version='2.0', os_metrics_api_version='1', os_network_api_version='', os_object_api_version='', os_orchestration_api_version='1', os_project_id=None, os_project_name=None, os_queues_api_version='2', os_tripleoclient_api_version='1', os_volume_api_version='3', os_workflow_api_version='2', passcode='', password='***', profile='', project_domain_id='', project_domain_name='Default', project_id='', project_name='admin', protocol='', redirect_uri='', region_name='', remote_project_domain_id='', remote_project_domain_name='', remote_project_id='', remote_project_name='', roles='', service_provider='', service_provider_endpoint='', service_provider_entity_id='', system_scope='', timing=False, token='***', trust_id='', url='', user='', user_domain_id='', user_domain_name='Default', user_id='', username='admin', verbose_level=3, verify=None) Auth plugin password selected auth_config_hook(): {'auth_type': 'password', 'beta_command': False, 'tripleoclient_api_version': '1', u'compute_api_version': u'2', 'key': None, u'database_api_version': '1', 'metrics_api_version': '1', 'data_processing_api_version': '1.1', 'inspector_api_version': '1', 'auth_url': 'http://10.0.0.103:5000//v3', u'network_api_version': u'2', u'message': u'', u'image_format': u'qcow2', 'networks': [], u'image_api_version': '2', 'verify': True, u'dns_api_version': '2', u'object_store_api_version': u'1', 'username': 'admin', u'container_infra_api_version': '1', 'loadbalancer_api_version': '2.0', 'verbose_level': 3, 'region_name': '', 'api_timeout': None, u'baremetal_api_version': '1.37', 'queues_api_version': '2', 'auth': {'user_domain_name': 'Default', 'project_name': 'admin', 'project_domain_name': 'Default'}, 'default_domain': 'default', u'container_api_version': u'1', u'image_api_use_tasks': False, u'floating_ip_source': u'neutron', u'orchestration_api_version': '1', 'timing': False, 'password': '***', u'application_catalog_api_version': u'1', 'cacert': None, u'key_manager_api_version': '1', u'metering_api_version': u'2', 'deferred_help': False, u'identity_api_version': '3', u'workflow_api_version': '2', u'volume_api_version': '3', 'cert': None, u'secgroup_source': u'neutron', u'status': u'active', 'alarming_api_version': '2', 'debug': True, u'interface': None, u'disable_vendor_agent': {}} defaults: {u'auth_type': 'password', u'status': u'active', u'compute_api_version': u'2', 'key': None, u'database_api_version': u'1.0', 'api_timeout': None, u'baremetal_api_version': u'1', u'image_api_version': u'2', u'container_infra_api_version': u'1', u'metering_api_version': u'2', u'image_api_use_tasks': False, u'floating_ip_source': u'neutron', u'orchestration_api_version': u'1', 'cacert': None, u'network_api_version': u'2', u'message': u'', u'image_format': u'qcow2', u'application_catalog_api_version': u'1', u'key_manager_api_version': u'v1', u'workflow_api_version': u'2', 'verify': True, u'identity_api_version': u'2.0', u'volume_api_version': u'2', 'cert': None, u'secgroup_source': u'neutron', u'container_api_version': u'1', u'dns_api_version': u'2', u'object_store_api_version': u'1', u'interface': None, u'disable_vendor_agent': {}} cloud cfg: {'auth_type': 'password', 'beta_command': False, 'tripleoclient_api_version': '1', u'compute_api_version': u'2', 'key': None, u'database_api_version': '1', 'metrics_api_version': '1', 'data_processing_api_version': '1.1', 'inspector_api_version': '1', 'auth_url': 'http://10.0.0.103:5000//v3', u'network_api_version': u'2', u'message': u'', u'image_format': u'qcow2', 'networks': [], u'image_api_version': '2', 'verify': True, u'dns_api_version': '2', u'object_store_api_version': u'1', 'username': 'admin', u'container_infra_api_version': '1', 'loadbalancer_api_version': '2.0', 'verbose_level': 3, 'region_name': '', 'api_timeout': None, u'baremetal_api_version': '1.37', 'queues_api_version': '2', 'auth': {'user_domain_name': 'Default', 'project_name': 'admin', 'project_domain_name': 'Default'}, 'default_domain': 'default', u'container_api_version': u'1', u'image_api_use_tasks': False, u'floating_ip_source': u'neutron', u'orchestration_api_version': '1', 'timing': False, 'password': '***', u'application_catalog_api_version': u'1', 'cacert': None, u'key_manager_api_version': '1', u'metering_api_version': u'2', 'deferred_help': False, u'identity_api_version': '3', u'workflow_api_version': '2', u'volume_api_version': '3', 'cert': None, u'secgroup_source': u'neutron', u'status': u'active', 'alarming_api_version': '2', 'debug': True, u'interface': None, u'disable_vendor_agent': {}} compute API version 2, cmd group openstack.compute.v2 network API version 2, cmd group openstack.network.v2 image API version 2, cmd group openstack.image.v2 volume API version 3, cmd group openstack.volume.v3 identity API version 3, cmd group openstack.identity.v3 object_store API version 1, cmd group openstack.object_store.v1 orchestration API version 1, cmd group openstack.orchestration.v1 messaging API version 2, cmd group openstack.messaging.v2 workflow_engine API version 2, cmd group openstack.workflow_engine.v2 baremetal API version 1.37, cmd group openstack.baremetal.v1 baremetal_introspection API version 1, cmd group openstack.baremetal_introspection.v1 neutronclient API version 2, cmd group openstack.neutronclient.v2 tripleoclient API version 1, cmd group openstack.tripleoclient.v1 dns API version 2, cmd group openstack.dns.v2 load_balancer API version 2.0, cmd group openstack.load_balancer.v2 database API version 1, cmd group openstack.database.v1 key_manager API version 1, cmd group openstack.key_manager.v1 alarming API version 2, cmd group openstack.alarming.v2 container_infra API version 1, cmd group openstack.container_infra.v1 data_processing API version 1.1, cmd group openstack.data_processing.v1 metric API version 1, cmd group openstack.metric.v1 Auth plugin password selected auth_config_hook(): {'auth_type': 'password', 'beta_command': False, 'tripleoclient_api_version': '1', u'compute_api_version': u'2', 'key': None, u'database_api_version': '1', 'metrics_api_version': '1', 'data_processing_api_version': '1.1', 'inspector_api_version': '1', 'auth_url': 'http://10.0.0.103:5000//v3', u'network_api_version': u'2', u'message': u'', u'image_format': u'qcow2', 'networks': [], u'image_api_version': '2', 'verify': True, u'dns_api_version': '2', u'object_store_api_version': u'1', 'username': 'admin', u'container_infra_api_version': '1', 'loadbalancer_api_version': '2.0', 'verbose_level': 3, 'region_name': '', 'api_timeout': None, u'baremetal_api_version': '1.37', 'queues_api_version': '2', 'auth': {'user_domain_name': 'Default', 'project_name': 'admin', 'project_domain_name': 'Default'}, 'default_domain': 'default', u'container_api_version': u'1', u'image_api_use_tasks': False, u'floating_ip_source': u'neutron', u'orchestration_api_version': '1', 'timing': False, 'password': '***', u'application_catalog_api_version': u'1', 'cacert': None, u'key_manager_api_version': '1', u'metering_api_version': u'2', 'deferred_help': False, u'identity_api_version': '3', u'workflow_api_version': '2', u'volume_api_version': '3', 'cert': None, u'secgroup_source': u'neutron', u'status': u'active', 'alarming_api_version': '2', 'debug': True, u'interface': None, u'disable_vendor_agent': {}} Auth plugin password selected auth_config_hook(): {'auth_type': 'password', 'beta_command': False, 'tripleoclient_api_version': '1', u'compute_api_version': u'2', 'key': None, u'database_api_version': '1', 'metrics_api_version': '1', 'data_processing_api_version': '1.1', 'inspector_api_version': '1', 'auth_url': 'http://10.0.0.103:5000//v3', u'network_api_version': u'2', u'message': u'', u'image_format': u'qcow2', 'networks': [], u'image_api_version': '2', 'verify': True, u'dns_api_version': '2', u'object_store_api_version': u'1', 'username': 'admin', u'container_infra_api_version': '1', 'loadbalancer_api_version': '2.0', 'verbose_level': 3, 'region_name': '', 'api_timeout': None, u'baremetal_api_version': '1.37', 'queues_api_version': '2', 'auth': {'user_domain_name': 'Default', 'project_name': 'admin', 'project_domain_name': 'Default'}, 'default_domain': 'default', u'container_api_version': u'1', u'image_api_use_tasks': False, u'floating_ip_source': u'neutron', u'orchestration_api_version': '1', 'timing': False, 'password': '***', u'application_catalog_api_version': u'1', 'cacert': None, u'key_manager_api_version': '1', u'metering_api_version': u'2', 'deferred_help': False, u'identity_api_version': '3', u'workflow_api_version': '2', u'volume_api_version': '3', 'cert': None, u'secgroup_source': u'neutron', u'status': u'active', 'alarming_api_version': '2', 'debug': True, u'interface': None, u'disable_vendor_agent': {}} command: server add floating ip -> openstackclient.compute.v2.server.AddFloatingIP (auth=True) Auth plugin password selected auth_config_hook(): {'auth_type': 'password', 'beta_command': False, 'tripleoclient_api_version': '1', u'compute_api_version': u'2', 'key': None, u'database_api_version': '1', 'metrics_api_version': '1', 'data_processing_api_version': '1.1', 'inspector_api_version': '1', 'auth_url': 'http://10.0.0.103:5000//v3', u'network_api_version': u'2', u'message': u'', u'image_format': u'qcow2', 'networks': [], u'image_api_version': '2', 'verify': True, u'dns_api_version': '2', u'object_store_api_version': u'1', 'username': 'admin', u'container_infra_api_version': '1', 'loadbalancer_api_version': '2.0', 'verbose_level': 3, 'region_name': '', 'api_timeout': None, u'baremetal_api_version': '1.37', 'queues_api_version': '2', 'auth': {'user_domain_name': 'Default', 'project_name': 'admin', 'project_domain_name': 'Default'}, 'default_domain': 'default', u'container_api_version': u'1', u'image_api_use_tasks': False, u'floating_ip_source': u'neutron', u'orchestration_api_version': '1', 'timing': False, 'password': '***', u'application_catalog_api_version': u'1', 'cacert': None, u'key_manager_api_version': '1', u'metering_api_version': u'2', 'deferred_help': False, u'identity_api_version': '3', u'workflow_api_version': '2', u'volume_api_version': '3', 'cert': None, u'secgroup_source': u'neutron', u'status': u'active', 'alarming_api_version': '2', 'debug': True, u'interface': None, u'disable_vendor_agent': {}} Using auth plugin: password Using parameters {'username': 'admin', 'project_name': 'admin', 'user_domain_name': 'Default', 'auth_url': 'http://10.0.0.103:5000//v3', 'password': '***', 'project_domain_name': 'Default'} Get auth_ref REQ: curl -g -i -X GET http://10.0.0.103:5000//v3 -H "Accept: application/json" -H "User-Agent: osc-lib/1.9.0 keystoneauth1/3.4.0 python-requests/2.14.2 CPython/2.7.5" Starting new HTTP connection (1): 10.0.0.103 http://10.0.0.103:5000 "GET //v3 HTTP/1.1" 200 192 RESP: [200] Date: Fri, 03 Aug 2018 17:46:03 GMT Server: Apache Vary: X-Auth-Token,Accept-Encoding x-openstack-request-id: req-9267108f-cc31-48b0-b123-db681b108acd Content-Encoding: gzip Content-Length: 192 Content-Type: application/json RESP BODY: {"version": {"status": "stable", "updated": "2018-02-28T00:00:00Z", "media-types": [{"base": "application/json", "type": "application/vnd.openstack.identity-v3+json"}], "id": "v3.10", "links": [{"href": "http://10.0.0.103:5000/v3/", "rel": "self"}]}} GET call to None for http://10.0.0.103:5000//v3 used request id req-9267108f-cc31-48b0-b123-db681b108acd Making authentication request to http://10.0.0.103:5000/v3/auth/tokens http://10.0.0.103:5000 "POST /v3/auth/tokens HTTP/1.1" 201 8877 {"token": {"is_domain": false, "methods": ["password"], "roles": [{"id": "77f366c4cc5e43549ba92aabfed4d5ed", "name": "admin"}], "expires_at": "2018-08-03T18:46:03.000000Z", "project": {"domain": {"id": "default", "name": "Default"}, "id": "976d61d7f3b04944976b6301649f6eac", "name": "admin"}, "catalog": [{"endpoints": [{"url": "http://10.0.0.103:8776/v3/976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "5726f900ee734a3a91e6a915059f8db0"}, {"url": "http://172.17.1.11:8776/v3/976d61d7f3b04944976b6301649f6eac", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "78524bdde8df4b7ea9dde0a7db09c374"}, {"url": "http://172.17.1.11:8776/v3/976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "f345b8a0cabe40a3a58c696d331c903b"}], "type": "volumev3", "id": "056c73312f2541bbac63bcff1c6f5bad", "name": "cinderv3"}, {"endpoints": [], "type": "metering", "id": "1ae85cc5391245b3a1a89cffc9ae4270", "name": "ceilometer"}, {"endpoints": [{"url": "http://172.17.1.11:5000", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "050c0b9e6d1d48ea8820f7f7d2d8cc31"}, {"url": "http://192.168.24.6:35357", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "22d913d9575f462ba174aae39bf92c5a"}, {"url": "http://10.0.0.103:5000", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "99fa492c9aaa4862ac31b093fb258360"}], "type": "identity", "id": "240a24b2a7024f12a7abf3e203def7de", "name": "keystone"}, {"endpoints": [{"url": "http://172.17.1.11:8778/placement", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "79793ed915d6472ca4634123afdbe251"}, {"url": "http://10.0.0.103:8778/placement", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "cb9f705647a4415bab721cadd66ef937"}, {"url": "http://172.17.1.11:8778/placement", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "e01aac4b09144c0fb279cb05631f585a"}], "type": "placement", "id": "3f17adc0344640b19d26439b7be4bb72", "name": "placement"}, {"endpoints": [{"url": "http://172.17.3.13:8080/v1/AUTH_976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "01a15967ae3d437c91b9e1ba42d1330b"}, {"url": "http://10.0.0.103:8080/v1/AUTH_976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "3d3b2307acad4ce5b8845a29852853f2"}, {"url": "http://172.17.3.13:8080", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "41a8ebefba944158ad51b44fcf61631c"}], "type": "object-store", "id": "55fd5e9b52cf44aba6e351c219097380", "name": "swift"}, {"endpoints": [{"url": "http://172.17.1.11:9292", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "03476e7676ce497099fe9cf4c17cc890"}, {"url": "http://10.0.0.103:9292", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "6d6ab61ea5cb40c09552a4f5933547f6"}, {"url": "http://172.17.1.11:9292", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "a33e48a987ce4bd1853052db79cc7d9e"}], "type": "image", "id": "5d86fef60eb84153a5543df7d46ddce4", "name": "glance"}, {"endpoints": [{"url": "http://172.17.1.11:8041", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "212cd1e5a33a49a9909e62d72c24dc5b"}, {"url": "http://10.0.0.103:8041", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "64330aaaed734f0fb2cca849b99833a5"}, {"url": "http://172.17.1.11:8041", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "683a1fe30b6549e6923162dd1e3461b3"}], "type": "metric", "id": "64653d491cab458f82065e8ff7d94f21", "name": "gnocchi"}, {"endpoints": [{"url": "http://172.17.1.11:8000/v1", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "6b1ad398e8624b43897ee3db919f68a4"}, {"url": "http://10.0.0.103:8000/v1", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "8a37fbee030b47ec80c54d73ad99c260"}, {"url": "http://172.17.1.11:8000/v1", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "f6aea73b5cef43bf986407bd7ff883b1"}], "type": "cloudformation", "id": "72d477d8ca284e6a8b2629c5fe12adf9", "name": "heat-cfn"}, {"endpoints": [{"url": "http://10.0.0.103:8774/v2.1", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "7ab393ded2f54bcb9a32c9cb1b59356e"}, {"url": "http://172.17.1.11:8774/v2.1", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "950c579cbea44f1fa5ab2a161fd62545"}, {"url": "http://172.17.1.11:8774/v2.1", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "958946ba2af6498babfd4c5793bd6b8a"}], "type": "compute", "id": "a03936be5cc3491bbce6c2c512bcb315", "name": "nova"}, {"endpoints": [{"url": "http://172.17.1.11:8042", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "1babb411308a4294ae36d4ab03d12acf"}, {"url": "http://172.17.1.11:8042", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "ad0ee0fec73048a8889d62785f431870"}, {"url": "http://10.0.0.103:8042", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "f0df6d95dfe44067932bb09ef96fbb62"}], "type": "alarming", "id": "a63c1632720146d786accea184e6bc7b", "name": "aodh"}, {"endpoints": [{"url": "http://10.0.0.103:8776/v1/976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "00b0893dfcee4d8a833bbe8c01bea3a8"}, {"url": "http://172.17.1.11:8776/v1/976d61d7f3b04944976b6301649f6eac", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "8a288eeebcd446238d6e344fb8a90940"}, {"url": "http://172.17.1.11:8776/v1/976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "ca687e23ef424f0695770933f3d0f0de"}], "type": "volume", "id": "bd699f4530ce43899e6932c9ed2a3455", "name": "cinder"}, {"endpoints": [{"url": "http://172.17.1.11:8776/v2/976d61d7f3b04944976b6301649f6eac", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "341b651fcd1d4e1facba3334db67e5f4"}, {"url": "http://10.0.0.103:8776/v2/976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "3556d396e70143558d2cf40b77889546"}, {"url": "http://172.17.1.11:8776/v2/976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "c682e0b1f1cd4673bdc0cdaad371affd"}], "type": "volumev2", "id": "ec9cef8f81494e1ea1bfde17c1fdf56b", "name": "cinderv2"}, {"endpoints": [{"url": "http://10.0.0.103:9696", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "194e42951c584e57a46c994827010a13"}, {"url": "http://172.17.1.11:9696", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "2f79dfaac0574045a0ac17e08f2e8ff3"}, {"url": "http://172.17.1.11:9696", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "5f238d29c2fe4208805a5e5f431d9771"}], "type": "network", "id": "f0d8ea0cfcc748a3861e09c4323332e6", "name": "neutron"}, {"endpoints": [{"url": "http://172.17.1.11:8977", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "550acf4cbaa44dbda33b04707214802d"}, {"url": "http://172.17.1.11:8977", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "59f24b82beab4c1fb20f888b0647126e"}, {"url": "http://10.0.0.103:8977", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "6d5b4bfd6cee40fba5f05f2165d29417"}], "type": "event", "id": "fd5baadd027043d5ba29eb226da962f2", "name": "panko"}, {"endpoints": [{"url": "http://10.0.0.103:8004/v1/976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "04e9821fc9194971a1bbdafe48b0a3ed"}, {"url": "http://172.17.1.11:8004/v1/976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "bba9d6ce86714c35aed6d98ed7b65509"}, {"url": "http://172.17.1.11:8004/v1/976d61d7f3b04944976b6301649f6eac", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "c8d73671a0924bf4a495d2c2cb4934c9"}], "type": "orchestration", "id": "fe12250bcbc445a1b5550fc21577ff7b", "name": "heat"}], "user": {"domain": {"id": "default", "name": "Default"}, "password_expires_at": null, "name": "admin", "id": "9622b9ce864b4a71bfdb92df14182053"}, "audit_ids": ["5sMLQ-gWR26RE13TAZQw0Q"], "issued_at": "2018-08-03T17:46:03.000000Z"}} run(Namespace(fixed_ip_address=None, ip_address=u'10.0.0.221', server=u'test-17719')) Instantiating compute client for API Version Major: 2, Minor: 0 Instantiating compute api: <class 'openstackclient.api.compute_v2.APIv2'> Making authentication request to http://10.0.0.103:5000/v3/auth/tokens http://10.0.0.103:5000 "POST /v3/auth/tokens HTTP/1.1" 201 8877 {"token": {"is_domain": false, "methods": ["password"], "roles": [{"id": "77f366c4cc5e43549ba92aabfed4d5ed", "name": "admin"}], "expires_at": "2018-08-03T18:46:04.000000Z", "project": {"domain": {"id": "default", "name": "Default"}, "id": "976d61d7f3b04944976b6301649f6eac", "name": "admin"}, "catalog": [{"endpoints": [{"url": "http://10.0.0.103:8776/v3/976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "5726f900ee734a3a91e6a915059f8db0"}, {"url": "http://172.17.1.11:8776/v3/976d61d7f3b04944976b6301649f6eac", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "78524bdde8df4b7ea9dde0a7db09c374"}, {"url": "http://172.17.1.11:8776/v3/976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "f345b8a0cabe40a3a58c696d331c903b"}], "type": "volumev3", "id": "056c73312f2541bbac63bcff1c6f5bad", "name": "cinderv3"}, {"endpoints": [], "type": "metering", "id": "1ae85cc5391245b3a1a89cffc9ae4270", "name": "ceilometer"}, {"endpoints": [{"url": "http://172.17.1.11:5000", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "050c0b9e6d1d48ea8820f7f7d2d8cc31"}, {"url": "http://192.168.24.6:35357", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "22d913d9575f462ba174aae39bf92c5a"}, {"url": "http://10.0.0.103:5000", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "99fa492c9aaa4862ac31b093fb258360"}], "type": "identity", "id": "240a24b2a7024f12a7abf3e203def7de", "name": "keystone"}, {"endpoints": [{"url": "http://172.17.1.11:8778/placement", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "79793ed915d6472ca4634123afdbe251"}, {"url": "http://10.0.0.103:8778/placement", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "cb9f705647a4415bab721cadd66ef937"}, {"url": "http://172.17.1.11:8778/placement", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "e01aac4b09144c0fb279cb05631f585a"}], "type": "placement", "id": "3f17adc0344640b19d26439b7be4bb72", "name": "placement"}, {"endpoints": [{"url": "http://172.17.3.13:8080/v1/AUTH_976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "01a15967ae3d437c91b9e1ba42d1330b"}, {"url": "http://10.0.0.103:8080/v1/AUTH_976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "3d3b2307acad4ce5b8845a29852853f2"}, {"url": "http://172.17.3.13:8080", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "41a8ebefba944158ad51b44fcf61631c"}], "type": "object-store", "id": "55fd5e9b52cf44aba6e351c219097380", "name": "swift"}, {"endpoints": [{"url": "http://172.17.1.11:9292", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "03476e7676ce497099fe9cf4c17cc890"}, {"url": "http://10.0.0.103:9292", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "6d6ab61ea5cb40c09552a4f5933547f6"}, {"url": "http://172.17.1.11:9292", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "a33e48a987ce4bd1853052db79cc7d9e"}], "type": "image", "id": "5d86fef60eb84153a5543df7d46ddce4", "name": "glance"}, {"endpoints": [{"url": "http://172.17.1.11:8041", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "212cd1e5a33a49a9909e62d72c24dc5b"}, {"url": "http://10.0.0.103:8041", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "64330aaaed734f0fb2cca849b99833a5"}, {"url": "http://172.17.1.11:8041", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "683a1fe30b6549e6923162dd1e3461b3"}], "type": "metric", "id": "64653d491cab458f82065e8ff7d94f21", "name": "gnocchi"}, {"endpoints": [{"url": "http://172.17.1.11:8000/v1", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "6b1ad398e8624b43897ee3db919f68a4"}, {"url": "http://10.0.0.103:8000/v1", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "8a37fbee030b47ec80c54d73ad99c260"}, {"url": "http://172.17.1.11:8000/v1", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "f6aea73b5cef43bf986407bd7ff883b1"}], "type": "cloudformation", "id": "72d477d8ca284e6a8b2629c5fe12adf9", "name": "heat-cfn"}, {"endpoints": [{"url": "http://10.0.0.103:8774/v2.1", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "7ab393ded2f54bcb9a32c9cb1b59356e"}, {"url": "http://172.17.1.11:8774/v2.1", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "950c579cbea44f1fa5ab2a161fd62545"}, {"url": "http://172.17.1.11:8774/v2.1", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "958946ba2af6498babfd4c5793bd6b8a"}], "type": "compute", "id": "a03936be5cc3491bbce6c2c512bcb315", "name": "nova"}, {"endpoints": [{"url": "http://172.17.1.11:8042", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "1babb411308a4294ae36d4ab03d12acf"}, {"url": "http://172.17.1.11:8042", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "ad0ee0fec73048a8889d62785f431870"}, {"url": "http://10.0.0.103:8042", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "f0df6d95dfe44067932bb09ef96fbb62"}], "type": "alarming", "id": "a63c1632720146d786accea184e6bc7b", "name": "aodh"}, {"endpoints": [{"url": "http://10.0.0.103:8776/v1/976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "00b0893dfcee4d8a833bbe8c01bea3a8"}, {"url": "http://172.17.1.11:8776/v1/976d61d7f3b04944976b6301649f6eac", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "8a288eeebcd446238d6e344fb8a90940"}, {"url": "http://172.17.1.11:8776/v1/976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "ca687e23ef424f0695770933f3d0f0de"}], "type": "volume", "id": "bd699f4530ce43899e6932c9ed2a3455", "name": "cinder"}, {"endpoints": [{"url": "http://172.17.1.11:8776/v2/976d61d7f3b04944976b6301649f6eac", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "341b651fcd1d4e1facba3334db67e5f4"}, {"url": "http://10.0.0.103:8776/v2/976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "3556d396e70143558d2cf40b77889546"}, {"url": "http://172.17.1.11:8776/v2/976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "c682e0b1f1cd4673bdc0cdaad371affd"}], "type": "volumev2", "id": "ec9cef8f81494e1ea1bfde17c1fdf56b", "name": "cinderv2"}, {"endpoints": [{"url": "http://10.0.0.103:9696", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "194e42951c584e57a46c994827010a13"}, {"url": "http://172.17.1.11:9696", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "2f79dfaac0574045a0ac17e08f2e8ff3"}, {"url": "http://172.17.1.11:9696", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "5f238d29c2fe4208805a5e5f431d9771"}], "type": "network", "id": "f0d8ea0cfcc748a3861e09c4323332e6", "name": "neutron"}, {"endpoints": [{"url": "http://172.17.1.11:8977", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "550acf4cbaa44dbda33b04707214802d"}, {"url": "http://172.17.1.11:8977", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "59f24b82beab4c1fb20f888b0647126e"}, {"url": "http://10.0.0.103:8977", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "6d5b4bfd6cee40fba5f05f2165d29417"}], "type": "event", "id": "fd5baadd027043d5ba29eb226da962f2", "name": "panko"}, {"endpoints": [{"url": "http://10.0.0.103:8004/v1/976d61d7f3b04944976b6301649f6eac", "interface": "public", "region": "regionOne", "region_id": "regionOne", "id": "04e9821fc9194971a1bbdafe48b0a3ed"}, {"url": "http://172.17.1.11:8004/v1/976d61d7f3b04944976b6301649f6eac", "interface": "internal", "region": "regionOne", "region_id": "regionOne", "id": "bba9d6ce86714c35aed6d98ed7b65509"}, {"url": "http://172.17.1.11:8004/v1/976d61d7f3b04944976b6301649f6eac", "interface": "admin", "region": "regionOne", "region_id": "regionOne", "id": "c8d73671a0924bf4a495d2c2cb4934c9"}], "type": "orchestration", "id": "fe12250bcbc445a1b5550fc21577ff7b", "name": "heat"}], "user": {"domain": {"id": "default", "name": "Default"}, "password_expires_at": null, "name": "admin", "id": "9622b9ce864b4a71bfdb92df14182053"}, "audit_ids": ["s1IWB2ISS3KLQOmOq9luxA"], "issued_at": "2018-08-03T17:46:04.000000Z"}} REQ: curl -g -i -X GET http://10.0.0.103:8774/v2.1/servers/test-17719 -H "User-Agent: python-novaclient" -H "Accept: application/json" -H "X-Auth-Token: {SHA1}550dc53cd22f6d2efae7b9fe2fa9c0729aba86fc" Starting new HTTP connection (1): 10.0.0.103 http://10.0.0.103:8774 "GET /v2.1/servers/test-17719 HTTP/1.1" 404 85 RESP: [404] Date: Fri, 03 Aug 2018 17:46:04 GMT Server: Apache OpenStack-API-Version: compute 2.1 X-OpenStack-Nova-API-Version: 2.1 Vary: OpenStack-API-Version,X-OpenStack-Nova-API-Version x-openstack-request-id: req-4b23a43d-2718-46c8-9abd-fc2a1c4d470e x-compute-request-id: req-4b23a43d-2718-46c8-9abd-fc2a1c4d470e Content-Length: 85 Content-Type: application/json; charset=UTF-8 RESP BODY: {"itemNotFound": {"message": "Instance test-17719 could not be found.", "code": 404}} GET call to compute for http://10.0.0.103:8774/v2.1/servers/test-17719 used request id req-4b23a43d-2718-46c8-9abd-fc2a1c4d470e REQ: curl -g -i -X GET http://10.0.0.103:8774/v2.1/servers?name=test-17719 -H "User-Agent: python-novaclient" -H "Accept: application/json" -H "X-Auth-Token: {SHA1}550dc53cd22f6d2efae7b9fe2fa9c0729aba86fc" http://10.0.0.103:8774 "GET /v2.1/servers?name=test-17719 HTTP/1.1" 200 161 RESP: [200] Date: Fri, 03 Aug 2018 17:46:04 GMT Server: Apache OpenStack-API-Version: compute 2.1 X-OpenStack-Nova-API-Version: 2.1 Vary: OpenStack-API-Version,X-OpenStack-Nova-API-Version,Accept-Encoding x-openstack-request-id: req-5df20258-e64c-40fa-b310-5503083563a8 x-compute-request-id: req-5df20258-e64c-40fa-b310-5503083563a8 Content-Encoding: gzip Content-Length: 161 Content-Type: application/json RESP BODY: {"servers": [{"id": "7b45b8ff-221d-4e28-abd7-a3b2f6ec331d", "links": [{"href": "http://10.0.0.103:8774/v2.1/servers/7b45b8ff-221d-4e28-abd7-a3b2f6ec331d", "rel": "self"}, {"href": "http://10.0.0.103:8774/servers/7b45b8ff-221d-4e28-abd7-a3b2f6ec331d", "rel": "bookmark"}], "name": "test-17719"}]} GET call to compute for http://10.0.0.103:8774/v2.1/servers?name=test-17719 used request id req-5df20258-e64c-40fa-b310-5503083563a8 REQ: curl -g -i -X GET http://10.0.0.103:8774/v2.1/servers/7b45b8ff-221d-4e28-abd7-a3b2f6ec331d -H "User-Agent: python-novaclient" -H "Accept: application/json" -H "X-Auth-Token: {SHA1}550dc53cd22f6d2efae7b9fe2fa9c0729aba86fc" http://10.0.0.103:8774 "GET /v2.1/servers/7b45b8ff-221d-4e28-abd7-a3b2f6ec331d HTTP/1.1" 200 764 RESP: [200] Date: Fri, 03 Aug 2018 17:46:04 GMT Server: Apache OpenStack-API-Version: compute 2.1 X-OpenStack-Nova-API-Version: 2.1 Vary: OpenStack-API-Version,X-OpenStack-Nova-API-Version,Accept-Encoding x-openstack-request-id: req-0e67f9fd-023d-48c8-a181-8e799d4b2970 x-compute-request-id: req-0e67f9fd-023d-48c8-a181-8e799d4b2970 Content-Encoding: gzip Content-Length: 764 Content-Type: application/json RESP BODY: {"server": {"OS-EXT-STS:task_state": null, "addresses": {"private": [{"OS-EXT-IPS-MAC:mac_addr": "fa:16:3e:20:ea:1a", "version": 4, "addr": "192.168.100.6", "OS-EXT-IPS:type": "fixed"}]}, "links": [{"href": "http://10.0.0.103:8774/v2.1/servers/7b45b8ff-221d-4e28-abd7-a3b2f6ec331d", "rel": "self"}, {"href": "http://10.0.0.103:8774/servers/7b45b8ff-221d-4e28-abd7-a3b2f6ec331d", "rel": "bookmark"}], "image": {"id": "35f04811-326a-4dae-bef2-2ba323bde79d", "links": [{"href": "http://10.0.0.103:8774/images/35f04811-326a-4dae-bef2-2ba323bde79d", "rel": "bookmark"}]}, "OS-EXT-STS:vm_state": "active", "OS-EXT-SRV-ATTR:instance_name": "instance-00000001", "OS-SRV-USG:launched_at": "2018-08-03T15:44:21.000000", "flavor": {"id": "d17b3aa3-f1f7-434d-b900-9068c7588e6a", "links": [{"href": "http://10.0.0.103:8774/flavors/d17b3aa3-f1f7-434d-b900-9068c7588e6a", "rel": "bookmark"}]}, "id": "7b45b8ff-221d-4e28-abd7-a3b2f6ec331d", "security_groups": [{"name": "default"}], "user_id": "9622b9ce864b4a71bfdb92df14182053", "OS-DCF:diskConfig": "MANUAL", "accessIPv4": "", "accessIPv6": "", "progress": 0, "OS-EXT-STS:power_state": 1, "OS-EXT-AZ:availability_zone": "nova", "config_drive": "", "status": "ACTIVE", "updated": "2018-08-03T15:44:21Z", "hostId": "32fb16c4a0cb3d0908e5c75aceaa0da86a812c6e26b5934eed1fe64f", "OS-EXT-SRV-ATTR:host": "compute-1.localdomain", "OS-SRV-USG:terminated_at": null, "key_name": null, "OS-EXT-SRV-ATTR:hypervisor_hostname": "compute-1.localdomain", "name": "test-17719", "created": "2018-08-03T15:44:11Z", "tenant_id": "976d61d7f3b04944976b6301649f6eac", "os-extended-volumes:volumes_attached": [], "metadata": {}}} GET call to compute for http://10.0.0.103:8774/v2.1/servers/7b45b8ff-221d-4e28-abd7-a3b2f6ec331d used request id req-0e67f9fd-023d-48c8-a181-8e799d4b2970 add_floating_ip Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/cliff/app.py", line 400, in run_subcommand result = cmd.run(parsed_args) File "/usr/lib/python2.7/site-packages/osc_lib/command/command.py", line 41, in run return super(Command, self).run(parsed_args) File "/usr/lib/python2.7/site-packages/cliff/command.py", line 184, in run return_code = self.take_action(parsed_args) or 0 File "/usr/lib/python2.7/site-packages/openstackclient/compute/v2/server.py", line 266, in take_action server.add_floating_ip(parsed_args.ip_address, File "/usr/lib/python2.7/site-packages/novaclient/base.py", line 180, in __getattr__ raise AttributeError(k) AttributeError: add_floating_ip clean_up AddFloatingIP: add_floating_ip Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/osc_lib/shell.py", line 134, in run ret_val = super(OpenStackShell, self).run(argv) File "/usr/lib/python2.7/site-packages/cliff/app.py", line 279, in run result = self.run_subcommand(remainder) File "/usr/lib/python2.7/site-packages/osc_lib/shell.py", line 169, in run_subcommand ret_value = super(OpenStackShell, self).run_subcommand(argv) File "/usr/lib/python2.7/site-packages/cliff/app.py", line 400, in run_subcommand result = cmd.run(parsed_args) File "/usr/lib/python2.7/site-packages/osc_lib/command/command.py", line 41, in run return super(Command, self).run(parsed_args) File "/usr/lib/python2.7/site-packages/cliff/command.py", line 184, in run return_code = self.take_action(parsed_args) or 0 File "/usr/lib/python2.7/site-packages/openstackclient/compute/v2/server.py", line 266, in take_action server.add_floating_ip(parsed_args.ip_address, File "/usr/lib/python2.7/site-packages/novaclient/base.py", line 180, in __getattr__ raise AttributeError(k) AttributeError: add_floating_ip END return value: 1 (overcloud) [stack@undercloud-0 ~]$ openstack server list +--------------------------------------+------------+--------+-----------------------+--------+---------+ | ID | Name | Status | Networks | Image | Flavor | +--------------------------------------+------------+--------+-----------------------+--------+---------+ | 7b45b8ff-221d-4e28-abd7-a3b2f6ec331d | test-17719 | ACTIVE | private=192.168.100.6 | cirros | m1.tiny | +--------------------------------------+------------+--------+-----------------------+--------+---------+ Expected results: floating ip attached successfully Additional info: --- Additional comment from Archit Modi on 2018-08-03 15:14 EDT ---
The error message occurring this time is not the same as what's shown in the cloned bug. The error message this time is: "botocore.exceptions.ClientError: An error occurred (AttributeError) when calling the AssociateAddress operation (reached max retries: 4): Unknown error occurred." which is not coming from openstackclient. We discussed this in #rhos-compute today and I think I found the problem on the ec2-api server side: https://github.com/openstack/ec2-api/blob/0243b82bf03d7f54206a96a3ff650faa6a29211d/ec2api/api/address.py#L287-L321 On L321 there, it calls nova.servers.add_floating_ip but that method was removed back in January and released in novaclient version 10.0.0 [1]. I also saw a related commit [2] that added skips to unit tests that were calling removed novaclient floating ip APIs. So, this is broken upstream in the ec2-api itself and would need to be fixed there first. [1] https://github.com/openstack/python-novaclient/commit/01fb16533bf562f39fe822bc12b9cc34b8580359 [2] https://github.com/openstack/ec2-api/commit/66a5333f1b97b80f58b22e47276b9b0526554dfd
The nova-ec2 project upstream is not active anymore. We will check if some existing users are still using this EC2 feature. If not, we will start a deprecation process.
I'm going to need more information on how to reproduce this, because so far I'm unable. Unless this has somehow been fixed in master, which is where I tried this. ### List devstack's image $ aws --endpoint-url http://192.168.100.200:8788/ ec2 describe-images { "Images": [ { "Name": "cirros-0.3.5-x86_64-disk", "ImageId": "ami-960ef701", "State": "available", "Architecture": "", "ImageLocation": "None (cirros-0.3.5-x86_64-disk)", "RootDeviceType": "instance-store", "OwnerId": "e03ae3a775634c6f958847d00d0ebfb8", "CreationDate": "2018-11-02T16:03:34Z", "Public": true, "ImageType": "machine" } ] } ### Build instance $ aws --endpoint-url http://192.168.100.200:8788/ ec2 run-instances --image-id ami-960ef701 { "Instances": [ { "SourceDestCheck": true, "VpcId": "vpc-ae7809df", "Placement": { "AvailabilityZone": "" }, "InstanceId": "i-a9bcb481", "PublicDnsName": "", "ImageId": "ami-960ef701", "PrivateDnsName": "r-7fgosgej-0", "State": { "Code": 0, "Name": "error" }, "KeyName": "", "LaunchTime": "2018-11-02T17:46:54Z", "SubnetId": "subnet-2b41091f", "SecurityGroups": [ { "GroupName": "default", "GroupId": "sg-ae7809df" } ], "AmiLaunchIndex": 0, "InstanceType": "m1.small", "PrivateIpAddress": "172.31.0.3", "NetworkInterfaces": [ { "Status": "in-use", "MacAddress": "fa:16:3e:d6:61:fd", "SourceDestCheck": true, "VpcId": "vpc-ae7809df", "Description": "", "NetworkInterfaceId": "eni-a9e03c25", "PrivateIpAddresses": [ { "Primary": true, "PrivateIpAddress": "172.31.0.3" } ], "Attachment": { "Status": "attached", "DeviceIndex": 0, "DeleteOnTermination": true, "AttachmentId": "eni-attach-a9e03c25", "AttachTime": "2018-11-02T17:46:54.506151Z" }, "Groups": [ { "GroupName": "default", "GroupId": "sg-ae7809df" } ], "SubnetId": "subnet-2b41091f", "OwnerId": "ce1ef907e2bd477a8db4021c5bf19284", "PrivateIpAddress": "172.31.0.3" } ] } ], "ReservationId": "r-7fgosgej", "Groups": [], "OwnerId": "ce1ef907e2bd477a8db4021c5bf19284" } ### Allocate a "floating ip" $ aws --endpoint-url http://192.168.100.200:8788/ ec2 allocate-address { "PublicIp": "172.24.4.3", "Domain": "vpc", "AllocationId": "eipalloc-4e59f691" } ### Associate it with our instance $ aws --endpoint-url http://192.168.100.200:8788/ ec2 associate-address --instance-id i-a9bcb481 --public-ip 172.24.4.3 { "AssociationId": "eipassoc-4e59f691" }
Doh, as Ollie pointed out in comment #3, setting disable_ec2_classic=True works around this, and that's how devstack deploys the ec2api plugin. With disable_ec2_classic=False, I can reproduce with the steps in comment #5.
And as Melanie correctly pointed out in comment #1, it's because add_floating_ip no longer exists: Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api [req-e1509cd8-38e4-4b4e-9536-ee2cd0c4fe2d c4569976f00e4aa1a470925dec004abc ce1ef907e2bd477a8db4021c5bf19284 - - -] Unexpected Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api Traceback (most recent call last): Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api File "/opt/stack/ec2-api/ec2api/api/__init__.py", line 377, in __call__ Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api result = api_request.invoke(context) Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api File "/opt/stack/ec2-api/ec2api/api/apirequest.py", line 81, in invoke Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api result = method(context, **args) Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api File "/opt/stack/ec2-api/ec2api/api/cloud.py", line 78, in func_wrapped Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api return impl_func(context, **kwargs) Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api File "/opt/stack/ec2-api/ec2api/api/address.py", line 69, in associate_address Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api private_ip_address, allow_reassociation) Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api File "/opt/stack/ec2-api/ec2api/api/address.py", line 321, in associate_address Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api nova.servers.add_floating_ip(os_instance_id, public_ip) Nov 02 17:56:08 ubuntu ec2-api[13758]: 2018-11-02 17:56:08.617 13770 ERROR ec2api.api AttributeError: 'ServerManager' object has no attribute 'add_floating_ip'
While nova-network supported adding a floating IP to an instance, Neutron requires a port. So the `associate-address --instance-id <id> --public-ip <fip>` form of the command can only work if the insance has a single port with a single IP address. If that's not the case, the ec2api needs to throw some kind of exception, and require that the command be used with the `--private-ip-address` or `--network-interface-id` option. We would then loop up the Neutron port based on one of those parameters. Also, in addition to fixing this for the associate-address case (nova.servers.add_floating_ip), we'll also need to fix this for the disassociate-address case (nova.servers.remove_floating_ip). It's not hard work, but it's definitely not trivial. Before we embark on this, I want to make sure there are still customers using this in OSP14 and beyond.