Zun

Use one-subnet neutron port on dual stack network failed

Bug #1800375 reported by hongbin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Zun
Fix Committed
Medium
hongbin

Bug Description

Create a neutron port with dual stack (ipv4 and ipv6) network, then remove the ipv6 address from the neutron port. Run a container with this port will fail

Steps to reproduce:

openstack network create testnet
openstack subnet create --network testnet --subnet-range 10.10.10.0/24 testsubnetv4
openstack subnet create --network testnet --ip-version 6 --subnet-range 2002:db8::/64 testsubnetv6
openstack port create --network testnet testport
openstack port unset --fixed-ip ip-address=2002:db8::4,subnet=579afbd4-3da4-4ef6-be34-9b1cd9baa645 testport
zun run --name testcontainer --net port=testport nginx
zun show testcontainer
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Property | Value |
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
... |
| status_reason | Docker internal error: 500 Server Error: Internal Server Error ("IpamDriver.RequestAddress: Requested ip address {'subnet_id': u'89f09a66-0cd0-4992-b122-ed2971072a16'} already belongs to a bound Neutron port: 0c252270-4ae4-4a4e-8e0b-cc12f7f66a35"). |
| name | testcontainer |
... |
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

Kuryr's log:

Oct 28 18:04:36 octavia kuryr-server[23408]: 2018-10-28 18:04:36.363 23408 ERROR kuryr_libnetwork.utils [-] Unexpected error happened: Requested ip address {'subnet_id': u'89f09a66-0cd0-4992-b122-ed2971072a16'} already belongs to a bound Neutron port: 0c252270-4ae4-4a4e-8e0b-cc12f7f66a35: AddressInUseException: Requested ip address {'subnet_id': u'89f09a66-0cd0-4992-b122-ed2971072a16'} already belongs to a bound Neutron port: 0c252270-4ae4-4a4e-8e0b-cc12f7f66a35
Oct 28 18:04:36 octavia kuryr-server[23408]: Traceback (most recent call last):
Oct 28 18:04:36 octavia kuryr-server[23408]: File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1813, in full_dispatch_request
Oct 28 18:04:36 octavia kuryr-server[23408]: rv = self.dispatch_request()
Oct 28 18:04:36 octavia kuryr-server[23408]: File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1799, in dispatch_request
Oct 28 18:04:36 octavia kuryr-server[23408]: return self.view_functions[rule.endpoint](**req.view_args)
Oct 28 18:04:36 octavia kuryr-server[23408]: File "/opt/stack/kuryr-libnetwork/kuryr_libnetwork/controllers.py", line 1729, in ipam_request_address
Oct 28 18:04:36 octavia kuryr-server[23408]: existing_port, fixed_ip, req_mac_address)
Oct 28 18:04:36 octavia kuryr-server[23408]: File "/opt/stack/kuryr-libnetwork/kuryr_libnetwork/controllers.py", line 530, in _update_existing_port
Oct 28 18:04:36 octavia kuryr-server[23408]: existing_port['id']))
Oct 28 18:04:36 octavia kuryr-server[23408]: AddressInUseException: Requested ip address {'subnet_id': u'89f09a66-0cd0-4992-b122-ed2971072a16'} already belongs to a bound Neutron port: 0c252270-4ae4-4a4e-8e0b-cc12f7f66a35

Revision history for this message
hongbin (hongbin034) wrote :
Changed in zun:
assignee: nobody → hongbin (hongbin034)
importance: Undecided → Medium
status: New → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to zun-tempest-plugin (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/633106

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to zun-tempest-plugin (master)

Reviewed: https://review.openstack.org/633106
Committed: https://git.openstack.org/cgit/openstack/zun-tempest-plugin/commit/?id=b2313233978525444baa7d8b7f3a7f9aa90f1182
Submitter: Zuul
Branch: master

commit b2313233978525444baa7d8b7f3a7f9aa90f1182
Author: Hongbin Lu <email address hidden>
Date: Fri Jan 25 03:23:03 2019 +0000

    Test create ipv4 port on dual net

    Change-Id: I65b3ad02c450eea3f714a1fd02d60c3f395d925f
    Related-Bug: #1800375

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.