[ovs-dev] [PATCH] ovn.at: fix occasional failure - ACL reject rule test

Han Zhou zhouhan at gmail.com
Sat May 19 21:21:33 UTC 2018


The test fails occasionally because it may starts sending packets
before the new ACL related flows are installed on HVs, even if it
ensures lflows exist in SB DB. This patch ensure the HVs are in
sync by ovn-nbctl --wait=hv sync, and removes the check for lflow
readiness in SB.

Signed-off-by: Han Zhou <hzhou8 at ebay.com>
---
 tests/ovn.at | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/tests/ovn.at b/tests/ovn.at
index 8d9519e..0b4006f 100644
--- a/tests/ovn.at
+++ b/tests/ovn.at
@@ -9562,7 +9562,9 @@ done
 ovn-nbctl --log acl-add sw0 to-lport 1000 "outport == \"sw0-p12\"" reject
 ovn-nbctl --log acl-add sw0 from-lport 1000 "inport == \"sw0-p11\"" reject
 ovn-nbctl --log acl-add sw0 from-lport 1000 "inport == \"sw0-p21\"" reject
-OVS_WAIT_UNTIL([test 3 = $(ovn-sbctl lflow-list | grep 'icmp4 {' | wc -l)])
+
+# Allow some time for ovn-northd and ovn-controller to catch up.
+ovn-nbctl --timeout=3 --wait=hv sync
 
 test_ip_packet 11 1 000000000011 000000000021 $(ip_to_hex 192 168 1 11) $(ip_to_hex 192 168 1 21) 0000 7d8d fcfe
 test_ip_packet 21 2 000000000021 000000000011 $(ip_to_hex 192 168 1 21) $(ip_to_hex 192 168 1 11) 0000 7d8d fcfe
-- 
2.1.0



More information about the dev mailing list