diff options
author | Ryan Moats <rmoats@us.ibm.com> | 2016-07-22 21:54:26 +0000 |
---|---|---|
committer | Ben Pfaff <blp@ovn.org> | 2016-07-22 16:57:49 -0700 |
commit | ab39371d68842b7e4000cc5d8718e6fc04e92795 (patch) | |
tree | f0d5da334d070dac8d608cb2669e46d2a59f8f64 /tests | |
parent | 0ec19def8282720b59c0e2520a0633969b322739 (diff) | |
download | openvswitch-ab39371d68842b7e4000cc5d8718e6fc04e92795.tar.gz |
ovn-controller: Handle physical changes correctly
[1] reported increased failure rates in certain tests
with incremental processing (the numbers are the number of failures
seen in 100 tests):
2 ovn -- vtep: 3 HVs, 1 VIFs/HV, 1 GW, 1 LS
10 ovn -- 2 HVs, 2 LS, 1 lport/LS, 2 peer LRs
52 ovn -- 1 HV, 1 LS, 2 lport/LS, 1 LR
45 ovn -- 1 HV, 2 LSs, 1 lport/LS, 1 LR
23 ovn -- 2 HVs, 3 LS, 1 lport/LS, 2 peer LRs, static routes
53 ovn -- 2 HVs, 3 LRs connected via LS, static routes
32 ovn -- 2 HVs, 2 LRs connected via LS, gateway router
50 ovn -- icmp_reply: 1 HVs, 2 LSs, 1 lport/LS, 1 LR
These failures were caused by a combination of problems in
handling physical changes:
1. When a vif was removed, the localvif_to_ofport entry was not
removed.
2. When a physical change was detected, ovn-controller would wait
a poll cycle before processing the logical flow table.
This patch set addresses both of these issues while simultaneously
cleaning up the code in physical.c. A side effect is a modification
of where OF flows are dumped in the gateway router case that allowed
the root causes of this issue to be found.
With these changes, all of the above tests had a 100/100 success rate.
[1] http://openvswitch.org/pipermail/dev/2016-July/075803.html
Signed-off-by: Ryan Moats <rmoats@us.ibm.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/ovn.at | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/tests/ovn.at b/tests/ovn.at index 95aa822c4..614a4bbf6 100644 --- a/tests/ovn.at +++ b/tests/ovn.at @@ -3192,14 +3192,6 @@ ovn-sbctl list chassis ovn-sbctl list encap echo "---------------------" -echo "------ hv1 dump ----------" -as hv1 ovs-ofctl show br-int -as hv1 ovs-ofctl dump-flows br-int -echo "------ hv2 dump ----------" -as hv2 ovs-ofctl show br-int -as hv2 ovs-ofctl dump-flows br-int -echo "----------------------------" - # Packet to Expect at alice1 src_mac="000002010203" dst_mac="f00000010204" @@ -3211,6 +3203,14 @@ expected=${dst_mac}${src_mac}08004500001c000000003e110200${src_ip}${dst_ip}00351 as hv1 ovs-appctl netdev-dummy/receive hv1-vif1 $packet as hv1 ovs-appctl ofproto/trace br-int in_port=1 $packet +echo "------ hv1 dump after packet 1 ----------" +as hv1 ovs-ofctl show br-int +as hv1 ovs-ofctl dump-flows br-int +echo "------ hv2 dump after packet 1 ----------" +as hv2 ovs-ofctl show br-int +as hv2 ovs-ofctl dump-flows br-int +echo "----------------------------" + $PYTHON "$top_srcdir/utilities/ovs-pcap.in" hv2/vif1-tx.pcap | trim_zeros > received1.packets echo $expected | trim_zeros > expout AT_CHECK([cat received1.packets], [0], [expout]) @@ -3232,6 +3232,15 @@ sleep 1 # Send the packet again. as hv1 ovs-appctl netdev-dummy/receive hv1-vif1 $packet + +echo "------ hv1 dump after packet 2 ----------" +as hv1 ovs-ofctl show br-int +as hv1 ovs-ofctl dump-flows br-int +echo "------ hv2 dump after packet 2 ----------" +as hv2 ovs-ofctl show br-int +as hv2 ovs-ofctl dump-flows br-int +echo "----------------------------" + $PYTHON "$top_srcdir/utilities/ovs-pcap.in" hv2/vif1-tx.pcap | trim_zeros > received1.packets echo $expected | trim_zeros >> expout AT_CHECK([cat received1.packets], [0], [expout]) |