The '--no-wait' flag will not wait for ovs-vswitchd to reconfigure after
changes have been made to the database. This causes a race condition as
the bridge may or may not be up when 'ip addr flush dev $PUBLIC_BRIDGE' is
called. This commit removes the '--no-wait' flag which is safe as the
openvswitch services are already started earlier in stack.sh
Change-Id: I73ef1b731295d03b0f064c5f786196284c3e39ce
Closes-bug: #1328962
| ... | ... |
@@ -65,8 +65,9 @@ function _neutron_ovs_base_configure_l3_agent {
|
| 65 | 65 |
iniset $Q_L3_CONF_FILE DEFAULT external_network_bridge $PUBLIC_BRIDGE |
| 66 | 66 |
|
| 67 | 67 |
neutron-ovs-cleanup |
| 68 |
- sudo ovs-vsctl --no-wait -- --may-exist add-br $PUBLIC_BRIDGE |
|
| 69 |
- sudo ovs-vsctl --no-wait br-set-external-id $PUBLIC_BRIDGE bridge-id $PUBLIC_BRIDGE |
|
| 68 |
+ # --no-wait causes a race condition if $PUBLIC_BRIDGE is not up when ip addr flush is called |
|
| 69 |
+ sudo ovs-vsctl -- --may-exist add-br $PUBLIC_BRIDGE |
|
| 70 |
+ sudo ovs-vsctl br-set-external-id $PUBLIC_BRIDGE bridge-id $PUBLIC_BRIDGE |
|
| 70 | 71 |
# ensure no IP is configured on the public bridge |
| 71 | 72 |
sudo ip addr flush dev $PUBLIC_BRIDGE |
| 72 | 73 |
} |