updating allowed_address_pairs without any value or with action clear throws internal server

Bug #1351979 reported by Vedamurthy Joshi
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R2.0
Won't Fix
High
Prakash Bailkeri
R2.1
Won't Fix
High
Prakash Bailkeri
R3.0
Won't Fix
High
Prakash Bailkeri
Trunk
Invalid
High
Sachin Bansal

Bug Description

Build 1.10 2282

root@nodec22:/usr/lib/python2.7/dist-packages# neutron port-update 13c5ca47-ff5c-422e-beb5-7f68ae8d129b --allowed-address-pairs
Request Failed: internal server error while processing your request.
root@nodec22:/usr/lib/python2.7/dist-packages#

neutron/server.log:
==================
2014-08-03 12:18:00.196 ERROR [neutron.api.v2.resource] update failed
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/neutron/api/v2/resource.py", line 84, in resource
    result = method(request=request, **args)
  File "/usr/lib/python2.7/dist-packages/neutron/api/v2/base.py", line 460, in update
    allow_bulk=self._allow_bulk)
  File "/usr/lib/python2.7/dist-packages/neutron/api/v2/base.py", line 589, in prepare_request_body
    attr_vals['validate'][rule])
  File "/usr/lib/python2.7/dist-packages/neutron/extensions/allowedaddresspairs.py", line 45, in _validate_allowed_address_pairs
    for address_pair in address_pairs:
TypeError: 'bool' object is not iterable

Changed in juniperopenstack:
assignee: nobody → Prakash Bailkeri (prakashmb)
Revision history for this message
Vedamurthy Joshi (vedujoshi) wrote :

Same error when updating to clear the allowed address pair

root@nodec22:/usr/lib/python2.7/dist-packages# neutron port-update 13c5ca47-ff5c-422e-beb5-7f68ae8d129b --allowed-address-pairs action=clear Request Failed: internal server error while processing your request.
root@nodec22:/usr/lib/python2.7/dist-packages#

2014-08-03 12:30:00.547 ERROR [neutron.api.v2.resource] update failed
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/neutron/api/v2/resource.py", line 84, in resource
    result = method(request=request, **args)
  File "/usr/lib/python2.7/dist-packages/neutron/api/v2/base.py", line 460, in update
    allow_bulk=self._allow_bulk)
  File "/usr/lib/python2.7/dist-packages/neutron/api/v2/base.py", line 589, in prepare_request_body
    attr_vals['validate'][rule])
  File "/usr/lib/python2.7/dist-packages/neutron/extensions/allowedaddresspairs.py", line 45, in _validate_allowed_address_pairs
    for address_pair in address_pairs:
TypeError: 'NoneType' object is not iterable

Changed in juniperopenstack:
importance: Low → High
summary: - updating allowed_address_pairs without any value throws internal server
+ updating allowed_address_pairs without any value or with action clear
+ throws internal server
Revision history for this message
Ashish Ranjan (aranjan-n) wrote :

FIx is needed in core neutron. Prakash to attach patch with this bug and start the process of upstreaming.

Changed in juniperopenstack:
status: New → Confirmed
tags: added: releasenote
Changed in juniperopenstack:
milestone: r1.10-fcs → none
Revision history for this message
Prakash Bailkeri (prakashmb) wrote :

Problem:
neutron cli command to clear the allowed-address-pairs fails.

workaround:
Use REST interface to neutron to clear allowed address pair.

curl -i http://<ip>:9696/v2.0/ports/<port-uuid>.json -X PUT -H "X-Auth-Token: $Token" -H "Content-Type: application/json" -H "Accept: application/json" -H "User-Agent: python-neutronclient" -d '{"port": {"allowed_address_pairs": []}}'

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.