kuryr-libnetwork did not clean neutron port when use existed neutron network
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
kuryr-libnetwork |
Fix Released
|
Critical
|
Dongcan Ye |
Bug Description
Problem:
when user use existed neutron network, kuryr-libnetwork will not delete the neutron port which is created for containers.
Reproduce Steps:
1. create neutron network and subnet
2. create kuryr network with this existed neutron network.
3. run a container, and delete the container.
Expect Result:
the neutron port which created from container is deleted after the container is deleted.
Actual Result:
the neutron port did not delete.
When ipamdriver release address, it will find the subnet according to poolid. This will assume the subnet need has subnetpool-id. When "existed neutron network" case, the network and subnet is pre-created by EndUser, which do not have subnetpool-id. and subnetpool-id is unchangable after the subnet is created. This will cause kuryr can't release the neutron port.
summary: |
- kuryr-libnetwork did not clearn neutron port when use existed neutron + kuryr-libnetwork did not clean neutron port when use existed neutron network |
Changed in kuryr-libnetwork: | |
status: | New → Confirmed |
importance: | Undecided → Critical |
description: | updated |
Changed in kuryr-libnetwork: | |
assignee: | nobody → Dongcan Ye (hellochosen) |
Reviewed: https:/ /review. openstack. org/412772 /git.openstack. org/cgit/ openstack/ kuryr-libnetwor k/commit/ ?id=4af7e1cdd82 1bbda0319251f1a ae633a04573413
Committed: https:/
Submitter: Jenkins
Branch: master
commit 4af7e1cdd821bbd a0319251f1aae63 3a04573413
Author: Dongcan Ye <email address hidden>
Date: Tue Dec 20 14:20:57 2016 +0800
Delete port created by kuryr
In current code, we get the port's subnet by checking the libnetwork port undeleted.
subnet's subnetpool_id equal with the given PoolID, but in
existing environment, the subnet may lack subnetpool_id,
hence we will not get the port's subnet and leaves the
kuryr-
This patch checks the port's device owner and determines
the given POOL's subnet_id and ip_address is equal to
port's fixed_ips attribute.
Change-Id: I736adbb2409b50 a5e11d3aa7d3177 8944cfdeae1
Co-Authored-By: Liping Mao <email address hidden>
Closes-Bug: #1651015