Create and delete port timing windows with address sets
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
networking-ovn |
Fix Released
|
Medium
|
Han Zhou |
Bug Description
There is a timing window between create and delete port with respect to address sets. That is, deleting a port will result in its IP address being removed from its associated address sets. However, another port could be created at the same time taking over the IP address of the recently delete port. Depending on the sequence of events, the associated address sets may not contain the new ports IP address.
I was able to recreate this problem by adding a 15 second sleep in networking-ovn ML2 driver delete_
This timing window may also impact update and delete port flow, but the create and delete port flow is the more likely scenario.
$ openstack port create --network private --fixed-ip ip-address=10.0.0.4 port1
$ ovn-nbctl show
switch 45ba600a-
port e5a9abc7-
port 99e4526a-
port ea898f42-
...
$ ovn-nbctl list address_set
_uuid : 9e09ff9e-
addresses : ["10.0.0.4"]
external_ids : {"neutron:
name : "as_ip4_
...
# Run port create and delete at the same time.
$ openstack port delete port1
$ openstack port create --network private --fixed-ip ip-address=10.0.0.4 port2
$ ovn-nbctl show
switch 45ba600a-
port e5a9abc7-
port 99e4526a-
port 23ce3eda-
...
$ ovn-nbctl list address_set
_uuid : 9e09ff9e-
addresses : []
external_ids : {"neutron:
name : "as_ip4_
...
Changed in networking-ovn: | |
status: | New → Confirmed |
Fixing this bug should take into consideration https:/ /bugs.launchpad .net/networking -ovn/+bug/ 1611836.