list servers always returns all with 'ip6' filter

Bug #1450859 reported by David Kranz
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released

Bug Description

A tempest test was failing because it was trying to filter servers based on ip from an ipv6 subnet but was not using the 'ip6' query param. But the fix to use 'ip6' failed because all servers are returned instead of just the one with that ipv6 addr.

This is most easily seen by just doing:

nova list --ip6 xxx

which returns all servers vs

nova list --ip xxx

which returns none.

For reference, the actual failing call from

2015-05-01 15:53:56.426 | 2015-05-01 15:22:28,839 30116 INFO [tempest_lib.common.rest_client] Request (ListServerFiltersTestJSON:test_list_servers_filtered_by_ip): 200 GET 0.060s
2015-05-01 15:53:56.426 | 2015-05-01 15:22:28,840 30116 DEBUG [tempest_lib.common.rest_client] Request - Headers: {'X-Auth-Token': '<omitted>', 'Accept': 'application/json', 'Content-Type': 'application/json'}
2015-05-01 15:53:56.426 | Body: None
2015-05-01 15:53:56.426 | Response - Headers: {'content-type': 'application/json', 'x-compute-request-id': 'req-ac54be26-7689-4092-b42a-f3161c80295b', 'date': 'Fri, 01 May 2015 15:22:28 GMT', 'content-length': '1147', 'status': '200', 'connection': 'close', 'content-location': ''}
2015-05-01 15:53:56.426 | Body: {"servers": [{"id": "0ab24a98-9725-47cd-86c9-de907da24329", "links": [{"href": "", "rel": "self"}, {"href": "", "rel": "bookmark"}], "name": "ListServerFiltersTestJSON-instance-319015482"}, {"id": "3a8bef8f-4f20-4b9f-89b0-905a8f4ba726", "links": [{"href": "", "rel": "self"}, {"href": "", "rel": "bookmark"}], "name": "ListServerFiltersTestJSON-instance-313871351"}, {"id": "ce24a53a-f412-4fb5-8da5-c7d0cbdc5fba", "links": [{"href": "", "rel": "self"}, {"href": "", "rel": "bookmark"}], "name": "ListServerFiltersTestJSON-instance-950662797"}]}

Tags: api
Revision history for this message
Dr. Jens Harbott (j-harbott) wrote :

Seems like ip6 is missing from the list of allowed options for non-admin access:

DEBUG nova.api.openstack.compute.servers [req-ac54be26-7689-4092-b42a-f3161c80295b demo demo] Removing options 'ip6' from query remove_invalid_options /opt/stack/new/nova/nova/api/openstack/compute/

So "nova list --ip6 xxx" is just treated like "nova list".

Changed in nova:
status: New → In Progress
assignee: nobody → Dr. Jens Rosenboom (j-rosenboom-j)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

Fix proposed to branch: master

Changed in nova:
status: In Progress → Confirmed
assignee: Dr. Jens Rosenboom (j-rosenboom-j) → nobody
Changed in nova:
assignee: nobody → Jay Pipes (jaypipes)
status: Confirmed → In Progress
Jay Pipes (jaypipes)
Changed in nova:
assignee: Jay Pipes (jaypipes) → Dr. Jens Rosenboom (j-rosenboom-j)
importance: Undecided → Medium
Matt Riedemann (mriedem)
tags: added: api
Changed in nova:
assignee: Dr. Jens Rosenboom (j-rosenboom-j) → nobody
status: In Progress → Confirmed
Revision history for this message
Sean Dague (sdague) wrote :
Changed in nova:
status: Confirmed → Fix Released
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.