configure Fails with neutronclient.common.exceptions.BadRequest: Unrecognized attribute(s) 'port_security_enabled'

Bug #1693146 reported by Dominique Poulain
18
This bug affects 4 people
Affects Status Importance Assigned to Milestone
OpenStack Charm Testing
New
Undecided
Unassigned

Bug Description

Undercloud: OpenStack Mitaka w/ Keystone v2
revno: 298

Steps followed:

$ bzr branch lp:openstack-charm-testing openstack-charm-testing-local
[...]
$ cd openstack-charm-testing-local

patch bin/post-deploy-config to work around LP#1693144:

$ diff -u post-deploy-config.ori post-deploy-config
--- post-deploy-config.ori 2017-05-24 08:24:53.101691000 +0000
+++ post-deploy-config 2017-05-24 08:55:39.719445000 +0000
@@ -10,7 +10,7 @@
 from neutronclient.v2_0 import client as ne_client
 from novaclient import client as no_client

-import keystoneauth1.identity.v3 as keystoneauth1
+import keystoneauth1.identity.v2 as keystoneauth1
 import keystoneauth1.session as keystoneauth1_session

$ juju deployer -B -c default.yaml -d -v -s 20 -r 3 xenial-mitaka
[...]
./configure
[...]
Using default network name: foobar_admin_net
Configuring interface for instance 8a120a5b-29c0-464c-9099-03e0185a013d
Attaching interface to instance 8a120a5b-29c0-464c-9099-03e0185a013d
Traceback (most recent call last):
  File "./bin/post-deploy-config", line 135, in <module>
    result = neutron.create_port(body=new_port)
  File "/usr/lib/python3/dist-packages/neutronclient/v2_0/client.py", line 97, in with_params
    ret = self.function(instance, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/neutronclient/v2_0/client.py", line 654, in create_port
    return self.post(self.ports_path, body=body)
  File "/usr/lib/python3/dist-packages/neutronclient/v2_0/client.py", line 363, in post
    headers=headers, params=params)
  File "/usr/lib/python3/dist-packages/neutronclient/v2_0/client.py", line 298, in do_request
    self._handle_fault_response(status_code, replybody, resp)
  File "/usr/lib/python3/dist-packages/neutronclient/v2_0/client.py", line 273, in _handle_fault_response
    exception_handler_v20(status_code, error_body)
  File "/usr/lib/python3/dist-packages/neutronclient/v2_0/client.py", line 84, in exception_handler_v20
    request_ids=request_ids)
neutronclient.common.exceptions.BadRequest: Unrecognized attribute(s) 'port_security_enabled'
Neutron server returns request_ids: ['req-33d9bb95-88da-45a8-8024-d3868372291c']

A workaround is to comment out the {"port_security_enabled": False} pair in the new_port dictionary

$ diff -u post-deploy-config.ori post-deploy-config
--- post-deploy-config.ori 2017-05-24 08:24:53.101691000 +0000
+++ post-deploy-config 2017-05-24 08:58:51.435445000 +0000
@@ -10,7 +10,7 @@
 from neutronclient.v2_0 import client as ne_client
 from novaclient import client as no_client

-import keystoneauth1.identity.v3 as keystoneauth1
+import keystoneauth1.identity.v2 as keystoneauth1
 import keystoneauth1.session as keystoneauth1_session

@@ -129,7 +129,7 @@
                     "admin_state_up": True,
                     "name": "data-port",
                     "network_id": net_id,
- "port_security_enabled": False,
+ #"port_security_enabled": False,
                 }
             }
             result = neutron.create_port(body=new_port)

After making that change, configure completes successfully.

Tags: sts
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.