diff mbox series

[ovs-dev] test: Use check for ovn-nbctl --wait sync wherever possible.

Message ID c607bcc05343215d6a4a6ac00d6d50248897f930.1730735048.git.lorenzo.bianconi@redhat.com
State Superseded
Headers show
Series [ovs-dev] test: Use check for ovn-nbctl --wait sync wherever possible. | expand

Checks

Context Check Description
ovsrobot/apply-robot success apply and check: success
ovsrobot/github-robot-_Build_and_Test success github build: passed
ovsrobot/github-robot-_ovn-kubernetes success github build: passed

Commit Message

Lorenzo Bianconi Nov. 4, 2024, 3:45 p.m. UTC
Always use check with ovn-nbctl --wait={hv,sb} wherever possible

Reported-at: https://issues.redhat.com/browse/FDP-875
Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com>
---
 tests/ovn-controller.at  |  10 +--
 tests/ovn-ic.at          |   2 +-
 tests/ovn-northd.at      |  56 ++++++------
 tests/ovn-performance.at |   2 +-
 tests/ovn.at             | 190 +++++++++++++++++++--------------------
 tests/perf-northd.at     |   4 +-
 tests/system-ovn-kmod.at |   4 +-
 tests/system-ovn.at      | 126 +++++++++++++-------------
 8 files changed, 197 insertions(+), 197 deletions(-)

Comments

Ilya Maximets Nov. 4, 2024, 6:31 p.m. UTC | #1
On 11/4/24 16:45, Lorenzo Bianconi wrote:
> Always use check with ovn-nbctl --wait={hv,sb} wherever possible
> 
> Reported-at: https://issues.redhat.com/browse/FDP-875
> Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com>
> ---
>  tests/ovn-controller.at  |  10 +--
>  tests/ovn-ic.at          |   2 +-
>  tests/ovn-northd.at      |  56 ++++++------
>  tests/ovn-performance.at |   2 +-
>  tests/ovn.at             | 190 +++++++++++++++++++--------------------
>  tests/perf-northd.at     |   4 +-
>  tests/system-ovn-kmod.at |   4 +-
>  tests/system-ovn.at      | 126 +++++++++++++-------------
>  8 files changed, 197 insertions(+), 197 deletions(-)

Hi, Lorenzo.  Thanks for the patch!
 
But why only the sync commands?  I think all the ctl commands should be
checked.  If any of nb/sb-ctl commands fail unexpectedly, the meaning of
the test can change and we may also not really test what was intended in
the test scenario.

Best regards, Ilya Maximets.
diff mbox series

Patch

diff --git a/tests/ovn-controller.at b/tests/ovn-controller.at
index a2e451880..24a7db654 100644
--- a/tests/ovn-controller.at
+++ b/tests/ovn-controller.at
@@ -2577,7 +2577,7 @@  OVS_WAIT_UNTIL([check_ovsdb_zone lr0_snat $snat_zone])
 
 snat_req_zone=$port1_zone
 check ovn-nbctl set Logical_Router lr0 options:snat-ct-zone=$snat_req_zone
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ct_zones=$(ovn-appctl -t ovn-controller ct-zone-list)
 echo "$ct_zones"
@@ -2708,7 +2708,7 @@  as hv1
 ovs-vsctl add-br br-phys
 ovn_attach n1 br-phys 192.168.0.1
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 wait_row_count Chassis 1 name=hv1
 
 chassis_id=$(fetch_column Chassis _uuid name=hv1)
@@ -2749,7 +2749,7 @@  check ovn-nbctl lsp-add sw0 sw0-p1
 check ovn-nbctl lsp-set-addresses sw0-p1 "50:54:00:00:00:03 10.0.0.3 1000::3"
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVS_WAIT_FOR_OUTPUT([as hv1 ovs-ofctl dump-flows br-int table=OFTABLE_PHY_TO_LOG | grep -c in_port=1], [0],[dnl
 1
@@ -2799,7 +2799,7 @@  done
 RUN_OVN_NBCTL
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVS_WAIT_FOR_OUTPUT([as hv1 ovs-ofctl dump-flows br-int table=OFTABLE_LOCAL_OUTPUT | grep reg15=0x8000,metadata=0x1 | grep -c "controller(userdata=00.00.00.1b"], [0],[dnl
 3
@@ -2809,7 +2809,7 @@  for i in $(seq 1 280); do
     OVN_NBCTL(lsp-del sw0-p$i)
 done
 RUN_OVN_NBCTL
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 AT_CHECK([as hv1 ovs-ofctl dump-flows br-int table=OFTABLE_LOCAL_OUTPUT | grep -q controller], [1])
 
diff --git a/tests/ovn-ic.at b/tests/ovn-ic.at
index 33ad37f2e..975ebd3d2 100644
--- a/tests/ovn-ic.at
+++ b/tests/ovn-ic.at
@@ -77,7 +77,7 @@  check_row_count ic-sb:Datapath_Binding 1 transit_switch=ts2
 check_column "ts1 ts2" ic-sb:Datapath_Binding transit_switch
 check_column "ts1 ts2" nb:Logical_Switch name
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Check SB DP key
 ts1_key=$(fetch_column ic-sb:Datapath_Binding tunnel_key transit_switch=ts1)
diff --git a/tests/ovn-northd.at b/tests/ovn-northd.at
index d1f7f105c..fb1bdc453 100644
--- a/tests/ovn-northd.at
+++ b/tests/ovn-northd.at
@@ -1343,7 +1343,7 @@  ovn-nbctl --stateless lr-nat-add CR dnat_and_snat  172.16.1.2 50.0.0.11
 ovn-nbctl --is-exempted lr-nat-update-ext-ip DR dnat_and_snat 172.16.1.2 disallowed_range
 ovn-nbctl --is-exempted lr-nat-update-ext-ip CR dnat_and_snat 172.16.1.2 disallowed_range
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 ovn-sbctl dump-flows DR > drflows6
 AT_CAPTURE_FILE([drflows2])
@@ -1797,7 +1797,7 @@  ovn-nbctl lrp-add lr0 lr0-join 00:00:01:01:02:04 10.10.0.1/24
 ovn-nbctl set logical_router lr0 options:chassis=ch1
 ovn-nbctl lr-nat-add lr0 dnat 192.168.2.2 10.0.0.5
 ovn-nbctl set logical_router lr0 options:dnat_force_snat_ip=192.168.2.3
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 AT_CHECK([ovn-sbctl lflow-list lr0 | grep lr_in_unsnat | ovn_strip_lflows], [0], [dnl
   table=??(lr_in_unsnat       ), priority=0    , match=(1), action=(next;)
@@ -1895,7 +1895,7 @@  ovn-nbctl ls-add ls1
 ovn-nbctl ls-add ls2
 ovn-nbctl lsp-add ls1 lsp1
 ovn-nbctl lsp-add ls2 lsp2
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ls1_key=$(ovn-sbctl --columns tunnel_key --bare list Datapath_Binding ls1)
 ls2_key=$(ovn-sbctl --columns tunnel_key --bare list Datapath_Binding ls2)
 
@@ -1945,7 +1945,7 @@  ovn-nbctl ls-add ls1
 ovn-nbctl ls-add ls2
 ovn-nbctl lsp-add ls1 lsp1
 ovn-nbctl lsp-add ls2 lsp2
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ls1_key=$(ovn-sbctl --columns tunnel_key --bare list Datapath_Binding ls1)
 ls2_key=$(ovn-sbctl --columns tunnel_key --bare list Datapath_Binding ls2)
 
@@ -2018,7 +2018,7 @@  ovn-nbctl lr-lb-add lr lb9
 ovn-nbctl lr-lb-add lr lb10
 ovn-nbctl lr-lb-add lr lb11
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 lr_key=$(fetch_column sb:datapath_binding tunnel_key external_ids:name=lr)
 lb_as_v4="_rtr_lb_${lr_key}_ip4"
 lb_as_v6="_rtr_lb_${lr_key}_ip6"
@@ -2092,7 +2092,7 @@  AT_CHECK([ovn-sbctl lflow-list | grep "xreg0\[[0..47\]]" | grep -vE 'lr_in_admis
 # Test chassis redirect port.
 ovn-nbctl remove logical_router lr options chassis
 ovn-nbctl lrp-set-gateway-chassis lrp-public ch
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # Ingress router port ETH address is stored in lr_in_admission.
 AT_CHECK([ovn-sbctl lflow-list | grep -E "lr_in_admission.*xreg0\[[0..47\]]" | ovn_strip_lflows], [0], [dnl
@@ -2228,7 +2228,7 @@  lb4=$(fetch_column nb:load_balancer _uuid name=lb4)
 lbg=$(ovn-nbctl create load_balancer_group name=lbg)
 check ovn-nbctl add logical_switch  sw0 load_balancer_group $lbg
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 AT_CHECK([ovn-sbctl lflow-list | grep "ls_out_pre_lb.*priority=100" | grep reg0 | sort], [0], [dnl
 ])
 
@@ -2316,7 +2316,7 @@  ovn-nbctl set NB_Global . options:ignore_lsp_down=false
 ovn-nbctl ls-add sw0
 ovn-nbctl lsp-add sw0 sw0-p1 -- lsp-set-addresses sw0-p1 "aa:aa:aa:aa:aa:aa 10.0.0.1"
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 AT_CHECK([ovn-sbctl lflow-list | grep arp | grep 10\.0\.0\.1], [1], [ignore])
 
 ovn-nbctl --wait=sb set NB_Global . options:ignore_lsp_down=true
@@ -3539,7 +3539,7 @@  for direction in from to; do
     ovn-nbctl acl-add ls ${direction}-lport 2 "udp" allow-related
     ovn-nbctl acl-add ls ${direction}-lport 1 "ip" drop
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 flow_eth='eth.src == 00:00:00:00:00:01 && eth.dst == 00:00:00:00:00:02'
 flow_ip='ip.ttl==64 && ip4.src == 42.42.42.1 && ip4.dst == 66.66.66.66'
@@ -3572,7 +3572,7 @@  ct_next(ct_state=new|trk) {
 for direction in from to; do
     ovn-nbctl acl-add ls ${direction}-lport 4 tcp allow-stateless
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # TCP packets should not go to conntrack anymore.
 flow="inport == \"lsp1\" && ${flow_eth} && ${flow_ip} && ${flow_tcp}"
@@ -3598,7 +3598,7 @@  ovn-nbctl ls-lb-add ls lb-udp
 
 # Remove stateless for TCP.
 ovn-nbctl acl-del ls
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # TCP packets should go to conntrack.
 flow="inport == \"lsp1\" && ${flow_eth} && ${flow_ip} && ${flow_tcp}"
@@ -3632,7 +3632,7 @@  ct_lb_mark {
 for direction in from to; do
     ovn-nbctl acl-add ls ${direction}-lport 4 tcp allow-stateless
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # TCP packets should not go to conntrack for load balancing.
 flow="inport == \"lsp1\" && ${flow_eth} && ${flow_ip} && ${flow_tcp}"
@@ -3674,7 +3674,7 @@  for direction in from to; do
     ovn-nbctl acl-add pg ${direction}-lport 2 "udp" allow-related
     ovn-nbctl acl-add pg ${direction}-lport 1 "ip" drop
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 lsp1_inport=$(fetch_column Port_Binding tunnel_key logical_port=lsp1)
 echo $lsp1_inport
@@ -3708,7 +3708,7 @@  ct_next(ct_state=new|trk) {
 for direction in from to; do
     ovn-nbctl acl-add pg ${direction}-lport 4 tcp allow-stateless
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # TCP packets should not go to conntrack anymore.
 flow="inport == \"lsp1\" && ${flow_eth} && ${flow_ip} && ${flow_tcp}"
@@ -3734,7 +3734,7 @@  ovn-nbctl ls-lb-add ls lb-udp
 
 # Remove stateless for TCP.
 ovn-nbctl acl-del pg
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # TCP packets should go to conntrack.
 flow="inport == \"lsp1\" && ${flow_eth} && ${flow_ip} && ${flow_tcp}"
@@ -3768,7 +3768,7 @@  ct_lb_mark {
 for direction in from to; do
     ovn-nbctl acl-add pg ${direction}-lport 4 tcp allow-stateless
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # TCP packets should not go to conntrack for load balancing.
 flow="inport == \"lsp1\" && ${flow_eth} && ${flow_ip} && ${flow_tcp}"
@@ -3807,7 +3807,7 @@  for direction in from to; do
     ovn-nbctl acl-add ls ${direction}-lport 3 "tcp" allow-related
     ovn-nbctl acl-add ls ${direction}-lport 3 "udp" allow
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 flow_eth='eth.src == 00:00:00:00:00:01 && eth.dst == 00:00:00:00:00:02'
 flow_ip='ip.ttl==64 && ip4.src == 42.42.42.1 && ip4.dst == 66.66.66.66'
@@ -3831,7 +3831,7 @@  for direction in from to; do
     ovn-nbctl acl-add ls ${direction}-lport 1 tcp allow-stateless
     ovn-nbctl acl-add ls ${direction}-lport 1 udp allow-stateless
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # TCP packets should not go to conntrack anymore.
 flow="inport == \"lsp1\" && ${flow_eth} && ${flow_ip} && ${flow_tcp}"
@@ -7015,7 +7015,7 @@  check ovn-nbctl lsp-add ls1 lsp1 -- \
     lsp-set-options lsp1 router-port=lrp1
 
 # ensure initial flows are installed without is_chassis_resident match part
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows lr1 > lrflows
 AT_CAPTURE_FILE([lrflows])
 
@@ -7033,7 +7033,7 @@  wait_row_count Port_Binding 0 logical_port=cr-lrp1 options:always-redirect="true
 # make lrp a cr-port and check its flows
 check ovn-nbctl lrp-set-gateway-chassis lrp1 ch1
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows lr1 > lrflows
 AT_CAPTURE_FILE([lrflows])
 
@@ -7055,7 +7055,7 @@  wait_row_count Port_Binding 1 logical_port=cr-lrp1 options:always-redirect="true
 # there should not be is_chassis_resident part.
 check ovn-nbctl lsp-add ls1 lsp-vtep -- lsp-set-type lsp-vtep vtep
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows lr1 > lrflows
 AT_CAPTURE_FILE([lrflows])
 
@@ -7074,7 +7074,7 @@  wait_row_count Port_Binding 0 logical_port=cr-lrp1 options:always-redirect="true
 # delete vtep lport and check lrp has is_chassis_resident match part again.
 check ovn-nbctl lsp-del lsp-vtep
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows lr1 > lrflows
 AT_CAPTURE_FILE([lrflows])
 
@@ -7369,7 +7369,7 @@  ovn-nbctl lb-add lb0 172.16.1.10:80 10.0.0.1:80
 ovn-nbctl lr-lb-add R1 lb0
 ovn-nbctl lb-add lb1 172.16.1.10:8080 10.0.0.1:8080
 ovn-nbctl lr-lb-add R1 lb1
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 AT_CHECK([ovn-sbctl get Port_Binding S1-R1 nat_addresses |grep -q 172.16.1.10], [0])
 
@@ -7513,7 +7513,7 @@  rm log_flows
 
 # Now remove the label from the allow-related ACL.
 set_acl_options allow_related_acl 0 true
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 record_log_flows
 
@@ -7618,7 +7618,7 @@  rm log_flows
 
 # Now remove the label from the allow-related ACL.
 set_acl_options allow_related_acl 0 true
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 record_log_flows
 
@@ -9233,7 +9233,7 @@  lb1_uuid=$(fetch_column nb:load_balancer _uuid name=lb1)
 lbg=$(ovn-nbctl create load_balancer_group name=lbg -- \
     add load_balancer_group lbg load_balancer $lb1_uuid)
 ovn-nbctl add logical_router R1 load_balancer_group $lbg
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 ovn-sbctl dump-flows S0 > S0flows
 ovn-sbctl dump-flows S1 > S1flows
@@ -9569,7 +9569,7 @@  p1_uuid=$(fetch_column nb:Logical_Switch_Port _uuid name=sw0-p1)
 p2_uuid=$(fetch_column nb:Logical_Switch_Port _uuid name=sw0-p2)
 
 echo "p1 uuid - $p1_uuid"
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 check as northd ovn-appctl -t ovn-northd inc-engine/clear-stats
 foo_as_uuid=$(ovn-nbctl create address_set name=foo addresses=\"1.1.1.1\",\"1.1.1.2\")
@@ -12659,7 +12659,7 @@  AT_SETUP([Sampling_App incremental processing])
 
 ovn_start
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 check as northd ovn-appctl -t ovn-northd inc-engine/clear-stats
 
 ovn-nbctl create Sampling_App type="acl-new" id="42"
diff --git a/tests/ovn-performance.at b/tests/ovn-performance.at
index dbad83bbb..0d809ac83 100644
--- a/tests/ovn-performance.at
+++ b/tests/ovn-performance.at
@@ -547,7 +547,7 @@  OVN_CONTROLLER_EXPECT_HIT_COND(
 # Wait for port_binding change related flows
 hv5_ch=$(ovn-sbctl --bare --columns _uuid list chassis hv5)
 OVS_WAIT_UNTIL([ovn-sbctl find port_binding logical_port=cr-lr1-public chassis=$hv5_ch])
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 # Delete hv5 from gateway chassis. There should be no lflow_run.
 OVN_CONTROLLER_EXPECT_NO_HIT(
     [hv1 hv2 hv3 hv4 hv5], [lflow_run],
diff --git a/tests/ovn.at b/tests/ovn.at
index 10cd7a79b..cc25eb4e6 100644
--- a/tests/ovn.at
+++ b/tests/ovn.at
@@ -2997,7 +2997,7 @@  ovn-sbctl chassis-add hv0 geneve 127.0.0.1
 for i in 1 2 3; do
     ovn-nbctl lsp-add lsw0 lp$i
 done
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 for i in 1 2 3; do
     ovn-sbctl lsp-bind lp$i hv0
     if test $i = 1; then
@@ -3018,7 +3018,7 @@  ovn-nbctl acl-add lsw0 to-lport 1000 'eth.type == 0x1236 && outport == "lp3"' dr
 ovn-nbctl create Address_Set name=set1 addresses=\"f0:00:00:00:00:01\",\"f0:00:00:00:00:02\"
 ovn-nbctl acl-add lsw0 to-lport 1000 'eth.type == 0x1237 && eth.src == $set1 && outport == "lp3"' drop
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
 on_exit 'kill `cat ovn-trace.pid`'
@@ -3299,7 +3299,7 @@  done
 wait_for_ports_up
 OVN_WAIT_PATCH_PORT_FLOWS(["ln1" "ln2" "ln3"], ["hv1"] ["hv2"])
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
 
@@ -3467,7 +3467,7 @@  done
 
 
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 OVN_WAIT_PATCH_PORT_FLOWS(["ln-11" "ln-21"], ["hv-1" "hv-2"])
 
 ovn-sbctl dump-flows > sbflows
@@ -3614,7 +3614,7 @@  done
 
 
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-nbctl show
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
@@ -3766,7 +3766,7 @@  for i in 1 2; do
 done
 
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-nbctl show
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
@@ -4401,7 +4401,7 @@  for tag in 10 20; do
     done
 done
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows
 
 for tag in 10 20; do
@@ -5600,7 +5600,7 @@  test_arp 11 $sha $spa
 test_na 11 $sha $spa6
 wait_row_count MAC_Binding 1 ip="$spa" mac=\"$sha\"
 wait_row_count MAC_Binding 1 ip=\"$spa6\" mac=\"$sha\"
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Send an IP packet from lp21 to 192.168.1.100, which should go to lp11.
 
@@ -5621,7 +5621,7 @@  test_arp 12 $sha $spa
 test_na 11 $sha $spa6
 wait_row_count MAC_Binding 1 ip="$spa" mac=\"$sha\"
 wait_row_count MAC_Binding 1 ip=\"$spa6\" mac=\"$sha\"
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 # give to the hv the time to send queued ip packets
 sleep 1
 
@@ -9994,7 +9994,7 @@  ovn-nbctl --wait=sb lsp-add lsw0 lp1
 ovn-nbctl --wait=sb lsp-add lsw0 lp2
 ovn-nbctl lsp-set-addresses lp1 $lp1_mac
 ovn-nbctl lsp-set-addresses lp2 $lp2_mac
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 wait_for_ports_up
 
 ovn-nbctl acl-add lsw0 from-lport 1000 'tcp.dst==80' drop
@@ -10021,7 +10021,7 @@  ovn-nbctl --log --severity=alert --name=reject-flow acl-add lsw0 from-lport 1000
 ovn-nbctl acl-add lsw0 to-lport 1000 'tcp.dst==186' reject
 ovn-nbctl --log --severity=alert --name=reject-flow acl-add lsw0 to-lport 1000 'tcp.dst==187' reject
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
@@ -10144,7 +10144,7 @@  ovn-nbctl --wait=sb lsp-add lsw0 lp1
 ovn-nbctl --wait=sb lsp-add lsw0 lp2
 ovn-nbctl lsp-set-addresses lp1 $lp1_mac
 ovn-nbctl lsp-set-addresses lp2 $lp2_mac
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 wait_for_ports_up
 
 
@@ -10160,7 +10160,7 @@  check ovn-nbctl --wait=hv sync
 
 # Add an ACL that doesn't rate-limit logs.
 ovn-nbctl --log --severity=alert --name=http-acl3 acl-add lsw0 to-lport 1000 'tcp.dst==82' drop
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
@@ -10236,7 +10236,7 @@  ovn-nbctl --wait=sb lsp-add lsw0 lp1
 ovn-nbctl --wait=sb lsp-add lsw0 lp2
 ovn-nbctl lsp-set-addresses lp1 $lp1_mac
 ovn-nbctl lsp-set-addresses lp2 $lp2_mac
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 wait_for_ports_up
 
 ovn-appctl -t ovn-controller vlog/set file:dbg
@@ -10246,18 +10246,18 @@  ovn-nbctl meter-add http-rl1 drop 10 pktps
 ovn-nbctl --log --meter=http-rl1 acl-add lsw0 to-lport 1000 'tcp.dst==80' drop \
        -- --log --meter=http-rl1 acl-add lsw0 to-lport 1000 'tcp.dst==81' allow
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-meters br-int | grep meter], [0], [ignore], [ignore])
 
 # Delete acl1, meter should be kept in OVS
 ovn-nbctl acl-del lsw0 to-lport 1000 'tcp.dst==80'
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-meters br-int | grep meter], [0], [ignore], [ignore])
 
 # Delete acl2, meter should be deleted in OVS
 ovn-nbctl acl-del lsw0 to-lport 1000 'tcp.dst==81'
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-meters br-int | grep meter], [1])
 
 OVN_CLEANUP([hv])
@@ -10711,7 +10711,7 @@  AT_CHECK([test ! -z $bar2_zoneid])
 # two "wait=hv" before we are sure that the ct-zone-id is removed from
 # external_ids.
 ovn-nbctl --wait=hv lsp-del bar2
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 bar2_zoneid=$(as hv2 ovs-vsctl get bridge br-int external_ids:ct-zone-bar2)
 AT_CHECK([test  -z $bar2_zoneid])
@@ -10721,7 +10721,7 @@  AT_CHECK([test  -z $bar2_zoneid])
 ovn-nbctl --wait=hv lsp-add bar bar2 vm2 1 \
 -- lsp-set-addresses bar2 "f0:00:00:01:02:08 192.168.2.3"
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 bar2_zoneid=$(as hv2 ovs-vsctl get bridge br-int external_ids:ct-zone-bar2)
 AT_CHECK([test ! -z $bar2_zoneid])
@@ -12275,7 +12275,7 @@  check as hv3 ovs-vsctl set open . external-ids:ovn-bridge-mappings=phys:br-phys
 
 dnl Allow some time for ovn-northd and ovn-controller to catch up.
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVN_WAIT_PATCH_PORT_FLOWS(["ln-outside"], ["hv3"])
 
 (echo "---------NB dump-----"
@@ -12395,7 +12395,7 @@  OVN_WAIT_PATCH_PORT_FLOWS(["ln-alice"], ["hv2"])
 
 dnl Allow some time for ovn-controller to catch up.
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # ARP for router IP address from outside1
 test_arp 3 1 f00000010204 $outside_ip $rtr_ip 000002010203
@@ -13276,7 +13276,7 @@  packet=${dst_mac}${src_mac}08004500001c0000000040110000${src_ip}${dst_ip}0035111
 # mac_bindings table.
 as hv1 ovs-appctl netdev-dummy/receive hv1-vif1 $packet
 wait_row_count MAC_Binding 1 ip="10.0.0.2"
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Packet to Expect at 'alice1'
 src_mac="000000010204"
@@ -13330,7 +13330,7 @@  for i in 1 2; do
 done
 
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows
 
 OVN_POPULATE_ARP
@@ -14634,7 +14634,7 @@  ovs-vsctl -- add-port br-int hv2-vif1 -- \
     ofport-request=1
 ovs-vsctl set open . external-ids:ovn-bridge-mappings=phys:br-phys
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 wait_for_ports_up
 
 ovn-sbctl dump-flows > sbflows
@@ -15212,7 +15212,7 @@  OVS_WAIT_UNTIL([test `as hv2 ovs-vsctl get Interface migrator external_ids:ovn-i
 
 # Still, this does not guarantee that all flows are installed on hv3: hv3 (might) still need to receive and handle
 # additional_chassis for migrator port
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # check that...
 # unicast from First arrives to hv1:Migrator
@@ -15301,7 +15301,7 @@  wait_column "" Port_Binding requested_additional_chassis logical_port=migrator
 OVS_WAIT_UNTIL([test `as hv2 ovs-vsctl get Interface migrator external_ids:ovn-installed` = '"true"'])
 
 # Give time for hv3 to handle the change of Port_Binding  for migrator port
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # check that...
 # unicast from Third doesn't arrive to hv1:Migrator
@@ -17309,7 +17309,7 @@  check ovn-nbctl acl-add sw0 to-lport 1002 ip reject
 OVN_POPULATE_ARP
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Get the OF table numbers
 acl_eval=$(ovn-debug lflow-stage-to-oftable ls_out_acl_eval)
@@ -18528,7 +18528,7 @@  ovn-nbctl --id=@p get Logical_Switch_Port lp2 -- add Port_Group pg1 ports @p
 ovn-nbctl --id=@p get Logical_Switch_Port lp2 -- add Port_Group pg2 ports @p
 ovn-nbctl --id=@p get Logical_Switch_Port lp3 -- add Port_Group pg2 ports @p
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 dnl Check if port group address sets were populated with ports' addresses
 check_column '10.0.0.1 10.0.0.2' Address_Set addresses name=pg1_ip4
@@ -18579,7 +18579,7 @@  ovn-nbctl --id=@p get Logical_Switch_Port lp2 -- add Port_Group pg1 ports @p
 ovn-nbctl --id=@p get Logical_Switch_Port lp2 -- add Port_Group pg2 ports @p
 ovn-nbctl --id=@p get Logical_Switch_Port lp3 -- add Port_Group pg2 ports @p
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 dnl Check if port group address sets were populated with ports' addresses
 AT_CHECK(
@@ -18796,7 +18796,7 @@  ovn-nbctl acl-del ls1 to-lport 1001 \
 'ip4 && ip4.src == $set1 && ip4.dst == $set1'
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 # priority=2001,ip,metadata=0x1,nw_dst=10.0.0.10 actions=conjunction(10,1/2)
 # priority=2001,ip,metadata=0x1,nw_dst=10.0.0.8 actions=conjunction(11,1/2)
 # priority=2001,ip,metadata=0x1,nw_dst=10.0.0.9 actions=conjunction(10,1/2),conjunction(11,1/2)
@@ -18817,7 +18817,7 @@  old_conj_ids=`as hv1 ovs-ofctl dump-flows br-int | grep conj_id= | \
 echo $old_conj_ids
 
 as hv1 ovn-appctl -t ovn-controller recompute
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 new_conj_ids=`as hv1 ovs-ofctl dump-flows br-int | grep conj_id= | \
               awk -F 'conj_id=' '{ print $2 }' | awk -F ',' '{ print $1 }' | sort`
 echo $new_conj_ids
@@ -18887,7 +18887,7 @@  ovn-nbctl acl-del pg1 to-lport 1000 "outport==@pg1 && ip4 && ip4.src == {10.0.0.
 ovn-nbctl acl-del pg2 to-lport 1000 "outport==@pg2 && ip4 && ip4.src == {10.0.0.1, 10.0.0.2}"
 ovn-nbctl acl-add pg1 to-lport 1000 "outport==@pg1 && ip4 && ip4.src == {10.0.0.1, 10.0.0.2}" allow
 ovn-nbctl acl-add pg2 to-lport 1000 "outport==@pg2 && ip4 && ip4.src == {10.0.0.1, 10.0.0.2}" allow
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Now re-bind p3 and p5 in the same transaction, so that pg1 and pg2 update are
 # handled in the same I-P engine run. The order of pg1 and pg2 can be random.
@@ -18901,7 +18901,7 @@  ovn-nbctl --wait=hv sync
 #    combined conjunctions.
 ovs-vsctl add-port br-int p3 -- set Interface p3 external_ids:iface-id=p3 -- \
     add-port br-int p5 -- set Interface p5 external_ids:iface-id=p5
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Now making sure we end up with two combined conjunctions.
 OVS_WAIT_UNTIL([test 2 = `as hv1 ovs-ofctl dump-flows br-int | \
@@ -19558,7 +19558,7 @@  done
 OVN_POPULATE_ARP
 # allow some time for ovn-northd and ovn-controller to catch up.
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 test_ip_packet 1 1 000000000001 00000000ff01 $(ip_to_hex 192 168 1 1) $(ip_to_hex 192 168 2 1) $(ip_to_hex 192 168 1 254) 0000 f87c ea96 yes
 test_ip6_packet 1 1 000000000001 00000000ff01 20010db8000100000000000000000011 20010db8000200000000000000000011 20010db8000100000000000000000001 1c22 yes
@@ -19783,7 +19783,7 @@  done
 OVN_POPULATE_ARP
 # allow some time for ovn-northd and ovn-controller to catch up.
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
@@ -19948,7 +19948,7 @@  ovn-nbctl set Logical_Switch_Port ls1-lr0 type=router \
 # Create HA chassis group
 ovn-nbctl ha-chassis-group-add hagrp1
 ovn-nbctl ha-chassis-group-add-chassis hagrp1 hv1 30
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 hagrp1_uuid=`ovn-nbctl --bare --columns _uuid find ha_chassis_group name="hagrp1"`
 
@@ -21120,7 +21120,7 @@  test_ip6_packet_larger_ext() {
 }
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ovn-nbctl show > nbdump
 AT_CAPTURE_FILE([nbdump])
@@ -21203,7 +21203,7 @@  ovn-nbctl lsp-set-options public-lr1 router-port=lr1-public
 
 ovn-nbctl lr-nat-add lr1 snat 172.168.0.100 10.0.0.0/24
 ovn-nbctl lr-nat-add lr1 snat 2000::1 1000::/64
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 dp_uuid=$(ovn-sbctl find datapath_binding | grep sw0 -B2 | grep _uuid | \
 awk '{print $3}')
@@ -21373,7 +21373,7 @@  ovn-nbctl lr-nat-add lr0 snat 2002::1 2001::/64
 
 OVN_POPULATE_ARP
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
@@ -21417,7 +21417,7 @@  OVN_CHECK_PACKETS([hv2/vif1-tx.pcap], [expected])
 ovn-nbctl lr-nat-del lr0 snat
 ovn-nbctl lr-nat-add lr0 dnat_and_snat 172.16.1.2 192.168.1.3 sw0-p1 f0:00:00:01:02:04
 ovn-nbctl lr-route-add lr0 172.16.2.0/24 172.16.1.11
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 ovn-sbctl dump-flows > sbflows2
 AT_CAPTURE_FILE([sbflows2])
 
@@ -21923,7 +21923,7 @@  ovn-nbctl lsp-add ls1 ls1-to-router -- set Logical_Switch_Port ls1-to-router typ
 ovn-nbctl lsp-add ls2 ls2-to-router -- set Logical_Switch_Port ls2-to-router type=router options:router-port=router-to-ls2 -- lsp-set-addresses ls2-to-router router
 
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 #ovn-sbctl dump-flows
 for i in 1 2; do
     for j in 1 2; do
@@ -22148,7 +22148,7 @@  check ovn-nbctl lr-nat-add lr0 dnat_and_snat 2001:db8::61d1 1000::61d1 sw0-vir6
 OVN_POPULATE_ARP
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Get the OF table numbers
 acl_eval=$(ovn-debug lflow-stage-to-oftable ls_out_acl_eval)
@@ -22545,7 +22545,7 @@  ovn-nbctl lsp-set-type sw0-vir virtual
 ovn-nbctl set logical_switch_port sw0-vir options:virtual-ip=10.0.0.10
 ovn-nbctl set logical_switch_port sw0-vir options:virtual-parents=sw0-p1,sw0-p2,sw0-p3
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Check that logical flows are added for sw0-vir in lsp_in_arp_rsp pipeline
 # with bind_vport action.
@@ -23244,7 +23244,7 @@  ovn-nbctl set Logical_Router_Port rtr-sw2 options:mcast_flood='true'
 # Enable mcast_flood on sw2-p1
 ovn-nbctl set Logical_Switch_Port sw2-p1 options:mcast_flood='true'
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Inject IGMP Join for 239.0.1.68 on sw1-p12.
 send_igmp_v3_report hv1-vif2 hv1 \
@@ -23313,7 +23313,7 @@  dp=$(fetch_column Datapath_Binding _uuid external_ids:name=sw2)
 ch=$(fetch_column Chassis _uuid name=hv3)
 ovn-sbctl create IGMP_Group address=239.0.1.42 datapath=$dp chassis=$ch chassis_name=hv3
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 wait_row_count IGMP_Group 2 address=239.0.1.68
 wait_row_count IGMP_Group 1 address=239.0.1.42
 
@@ -24439,7 +24439,7 @@  m4_define([DVR_N_S_ARP_HANDLING],
    # Set a hypervisor as gateway chassis, for router port 172.31.0.1
    ovn-nbctl lrp-set-gateway-chassis router-to-underlay hv3
    wait_for_ports_up
-   ovn-nbctl --wait=sb sync
+   check ovn-nbctl --wait=sb sync
    OVN_WAIT_PATCH_PORT_FLOWS(["ln1"] ["ln2"], ["hv1"] ["hv2"] ["hv3"])
    OVN_WAIT_PATCH_PORT_FLOWS(["ln4"], ["hv4"])
 
@@ -24669,7 +24669,7 @@  m4_define([DVR_N_S_PING],
    ovn-nbctl lrp-set-redirect-type router-to-underlay bridged
 
    wait_for_ports_up
-   ovn-nbctl --wait=sb sync
+   check ovn-nbctl --wait=sb sync
    OVN_WAIT_PATCH_PORT_FLOWS(["ln1"] ["ln2"], ["hv1"] ["hv2"] ["hv3"])
    OVN_WAIT_PATCH_PORT_FLOWS(["ln4"], ["hv4"])
 
@@ -24908,7 +24908,7 @@  ovn-nbctl lsp-set-options sw1-lr0 router-port=lr0-sw1
 
 OVN_POPULATE_ARP
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Get the OF table numbers
 learn_neigh=$(ovn-debug lflow-stage-to-oftable lr_in_learn_neighbor)
@@ -25107,7 +25107,7 @@  ovn-nbctl lsp-set-addresses lp11 "f0:00:00:00:00:11"
 ovn-nbctl lsp-set-port-security lp11 f0:00:00:00:00:11
 
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 ovn-nbctl show
 ovn-sbctl show
@@ -25190,7 +25190,7 @@  ovs-vsctl add-port br-int vif14 -- \
     set Interface vif14 external-ids:iface-id=lp14
 
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 # RARP packet for lp11
 echo "fffffffffffff000000000118100006580350001080006040003f0000000001100000000f0000000001100000000" > expected
@@ -25346,7 +25346,7 @@  ovn-nbctl --stateless lr-nat-add router dnat_and_snat 172.31.0.100 192.168.1.1
 ovn-nbctl lrp-set-redirect-type router-to-underlay bridged
 
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 OVN_WAIT_PATCH_PORT_FLOWS(["ln1"] ["ln2"] ["ln3"], ["hv1"] ["hv2"] ["hv3"])
 OVN_WAIT_PATCH_PORT_FLOWS(["ln4"], ["hv4"])
@@ -26014,7 +26014,7 @@  ovn-nbctl --wait=hv lrp-set-gateway-chassis lr0-public hv1 20
 
 OVN_POPULATE_ARP
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # And now for the anticlimax. We need to ensure that there is no
 # service monitor in the southbound db.
@@ -27651,7 +27651,7 @@  ovn-nbctl lsp-add sw sw-rtr                       \
     -- lsp-set-addresses sw-rtr 00:00:00:00:01:00 \
     -- lsp-set-options sw-rtr router-port=rtr-sw
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 wait_for_ports_up
 
 ovn-sbctl dump-flows > sbflows
@@ -28604,7 +28604,7 @@  ovn-nbctl lsp-add sw0 sw0-p2
 ovn-nbctl lsp-set-addresses sw0-p2 "50:54:00:00:00:04 10.0.0.4"
 ovn-nbctl lsp-set-port-security sw0-p2 "50:54:00:00:00:04 10.0.0.4"
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows > sbflows
 AT_CAPTURE_FILE([sbflows])
 
@@ -28668,7 +28668,7 @@  ovn-nbctl lsp-add sw0 sw0-p2
 ovn-nbctl lsp-set-addresses sw0-p2 "50:54:00:00:00:04 10.0.0.4"
 ovn-nbctl lsp-set-port-security sw0-p2 "50:54:00:00:00:04 10.0.0.4"
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 ovn-sbctl dump-flows > sbflows2
 AT_CAPTURE_FILE([sbflows2])
 
@@ -28753,7 +28753,7 @@  ovn-nbctl lr-add lr0
 ovn-nbctl lrp-add lr0 lr0-sw0 00:00:00:00:00:01 192.168.1.1/24 aef0:0:0:0:0:0:0:1/64
 
 wait_for_ports_up sw0-p1
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 
 sw0_dpkey=$(ovn-sbctl  --bare --columns tunnel_key list datapath_binding sw0)
 lr0_dpkey=$(ovn-sbctl  --bare --columns tunnel_key list datapath_binding lr0)
@@ -29000,7 +29000,7 @@  AT_CHECK([
 
 # Now make GW a gateway router on hv1
 ovn-nbctl set Logical_Router $gw_uuid options:chassis=hv1
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ovn-sbctl list logical_flow > lflows
 # And ensure that ECMP symmetric reply flows are present only on hv1
@@ -29130,7 +29130,7 @@  AT_CHECK([
 
 # Now make GW a gateway router on hv1
 ovn-nbctl set Logical_Router $gw_uuid options:chassis=hv1
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # And ensure that ECMP symmetric reply flows are present only on hv1
 as hv1 ovs-ofctl dump-flows br-int > hv1flows
@@ -29240,7 +29240,7 @@  ovs-vsctl -- add-port br-int hv2-vif1 -- \
 OVN_POPULATE_ARP
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 AT_CHECK([ovn-sbctl lflow-list | grep lr_in_arp_resolve | grep -F 10.0.0.1], [1], [])
 AT_CHECK([ovn-sbctl lflow-list | grep lr_in_arp_resolve | grep -F 10.0.0.2], [1], [])
@@ -29592,7 +29592,7 @@  ovs-vsctl -- add-port br-int hv1-vif2 -- \
 OVN_POPULATE_ARP
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Get the OF table numbers
 arp_resolve=$(ovn-debug lflow-stage-to-oftable lr_in_arp_resolve)
@@ -29622,7 +29622,7 @@  AT_CHECK([as hv1 ovs-ofctl dump-flows br-int | grep -E "table=$(ovn-debug lflow-
 
 # Use the router IP as SNAT IP.
 ovn-nbctl lr-nat-add r1 snat 10.0.1.1 10.8.8.0/24
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Send ip packets from p1 to lrp-r1-ext
 src_mac="f00000000102"
@@ -29760,7 +29760,7 @@  check test "$hvt2" -gt 0
 sleep 1
 check as hv3 ovn-appctl -t ovn-controller exit --restart
 wait_for_ports_up
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 wait_row_count Chassis_Private 9 name!=hv3 nb_cfg=2
 check_row_count Chassis_Private 1 name=hv3 nb_cfg=1
 
@@ -29937,7 +29937,7 @@  ovn-nbctl lr-nat-add gw_router snat 172.16.0.200 30.0.0.0/24
 ovn-nbctl lr-nat-add gw_router snat 172.16.0.201 30.0.0.3
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Create an interface in br-phys in hv2 and send ARP request for 172.16.0.100
 as hv2
@@ -30279,7 +30279,7 @@  ovs-vsctl -- add-port br-int hv1-vif1 -- \
     ofport-request=1
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Expected conjunction flows: None
 OVS_WAIT_UNTIL([test 0 = `as hv1 ovs-ofctl dump-flows br-int | \
@@ -30332,7 +30332,7 @@  as hv1 ovs-vsctl \
     -- add-port br-temp t1 \
     -- set Interface t1 external_ids:iface-id=sw0-p2
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # hv1 ovn-controller should not bind sw0-p2.
 wait_for_ports_up sw0-p1
@@ -30340,7 +30340,7 @@  check_row_count Port_Binding 0 logical_port=sw0-p2 chassis=$c
 
 # Trigger recompute and sw0-p2 should not be claimed.
 as hv1 ovn-appctl -t ovn-controller recompute
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 check_row_count Port_Binding 0 logical_port=sw0-p2 chassis=$ch
 
@@ -31664,7 +31664,7 @@  check ovn-nbctl lsp-add sw1 sw1-lr0
 check ovn-nbctl lsp-set-type sw1-lr0 router
 check ovn-nbctl lsp-set-addresses sw1-lr0 router
 check ovn-nbctl lsp-set-options sw1-lr0 router-port=lr0-sw1
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 net_add n1
 
@@ -32115,7 +32115,7 @@  check as hv1 ovs-vsctl set Interface vm1 external_ids:iface-id=foo
 check ovn-nbctl lsp-del vm-cont
 check as hv1 ovn-appctl -t ovn-controller debug/resume
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Make sure that ovn-controller has not asserted.
 AT_CHECK([kill -0 $(cat hv1/ovn-controller.pid)])
@@ -32335,7 +32335,7 @@  check ovn-nbctl lsp-del vm-cont
 check as hv1 ovn-appctl -t ovn-controller debug/resume
 check as hv1 ovs-vsctl set Interface vm1 external_ids:iface-id=foo
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Make sure that ovn-controller has not asserted.
 AT_CHECK([kill -0 $(cat hv1/ovn-controller.pid)])
@@ -32962,7 +32962,7 @@  ovs-vsctl -- add-port br-int hv1-vif1 -- \
 ovn-nbctl lr-route-add lr1 20.0.0.0/24 discard
 
 # Allow some time for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Check logical flows for drop rule
 AT_CHECK([ovn-sbctl dump-flows | grep lr_in_ip_routing | grep -F "20.0.0.0/24" | \
@@ -32989,7 +32989,7 @@  ovn-nbctl lr-route-del lr1 20.0.0.0/24
 ovn-nbctl --policy="src-ip" lr-route-add lr1 10.0.0.0/24 discard
 
 # Allow some time for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Check logical flows for drop rule
 AT_CHECK([ovn-sbctl dump-flows | grep lr_in_ip_routing | grep "10.0.0.0/24" | \
@@ -33462,7 +33462,7 @@  ovn-nbctl lrp-set-gateway-chassis DR-S1 hv2
 ovn-nbctl lrp-set-gateway-chassis DR-S2 hv3
 ovn-nbctl lrp-set-gateway-chassis DR-S3 hv4
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 OVN_POPULATE_ARP
 vif_to_ls () {
     case ${1} in dnl (
@@ -33698,7 +33698,7 @@  AT_CHECK([as hv2 ovs-ofctl dump-flows br-int table=$arp_rsp | grep -F 10.0.1.2],
 # doesn't remove.)
 check ovn-nbctl --wait=hv lrp-set-gateway-chassis lrp_lr_ls1 hv1 1
 as hv2 check ovn-appctl -t ovn-controller recompute
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 AT_CHECK([as hv2 ovs-ofctl dump-flows br-int table=$arp_rsp | grep -F 10.0.1.2], [1])
 
 # Enable dnat_and_snat on lr, and now hv2 should see flows for lsp1.
@@ -33738,7 +33738,7 @@  check as hv1 ovs-vsctl add-port br-int vif11 \
     -- set interface vif11 external_ids:iface-id=sw0-port1
 
 # sw0-port1 should not be claimed.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 check_column "" Port_Binding chassis logical_port=sw0-port1
 
 AT_CHECK([as hv1 ovn-appctl -t ovn-controller debug/dump-local-bindings], [0], [dnl
@@ -33763,7 +33763,7 @@  primary lport : [[sw0-port1]]
 
 # Clear the iface-id-ver from vif11 and hv1 ovn-controller should release it.
 check as hv1 ovs-vsctl remove interface vif11 external_ids iface-id-ver
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 check_column "" Port_Binding chassis logical_port=sw0-port1
 
 AT_CHECK([as hv1 ovn-appctl -t ovn-controller debug/dump-local-bindings], [0], [dnl
@@ -33787,7 +33787,7 @@  primary lport : [[sw0-port1]]
 # Set the options:iface-id-ver to sw0-port1 with different value.
 check ovn-nbctl lsp-set-options sw0-port1 iface-id-ver=bar
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 check_column "" Port_Binding chassis logical_port=sw0-port1
 
 AT_CHECK([as hv1 ovn-appctl -t ovn-controller debug/dump-local-bindings], [0], [dnl
@@ -33810,7 +33810,7 @@  primary lport : [[sw0-port1]]
 # Set a different iface-id-ver on vif11.
 check as hv1 ovs-vsctl set interface vif11 external_ids:iface-id-ver=bar2
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 check_column "" Port_Binding chassis logical_port=sw0-port1
 
 AT_CHECK([as hv1 ovn-appctl -t ovn-controller debug/dump-local-bindings], [0], [dnl
@@ -33823,7 +33823,7 @@  name: [[sw0-port1]], OVS interface name : [[vif11]], num binding lports : [[0]]
 # So sw0-port1 should be internally claimed without setting sw0-port1 to up.
 check ovn-nbctl lsp-set-type sw0-port1 localport
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 check_column "" Port_Binding chassis logical_port=sw0-port1
 
 AT_CHECK([as hv1 ovn-appctl -t ovn-controller debug/dump-local-bindings], [0], [dnl
@@ -33889,7 +33889,7 @@  grep sw0-port1 -c], [0], [1
 check as hv1 ovs-vsctl add-port br-int vif13 \
     -- set interface vif13 external_ids:iface-id=sw0-port2 ofport-request=13
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([test `ovs-ofctl dump-flows br-int table=OFTABLE_PHY_TO_LOG | grep "in_port=13" | wc -l` -eq 1])
 
 # There should be ct zone for sw0-port2 (localport).
@@ -34307,7 +34307,7 @@  OVS_WAIT_UNTIL([test x$(ovn-nbctl lsp-get-up lp11) = xup])
 
 ovn-nbctl lrp-set-gateway-chassis lr0-ext-ls0 hv1
 
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 OVN_POPULATE_ARP
 
 ovn-nbctl --wait=hv lr-nat-add lr0 snat 172.16.1.10 20.0.0.0/24
@@ -35910,7 +35910,7 @@  check ovs-vsctl add-port br-int p1 -- set interface p1 external_ids:iface-id=lsp
 check ovs-vsctl add-port br-int p2 -- set interface p2 external_ids:iface-id=lsp2
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Get the OF table numbers
 acl_eval=$(ovn-debug lflow-stage-to-oftable ls_in_acl_eval)
@@ -36001,7 +36001,7 @@  check ovs-vsctl add-port br-int p1 -- set interface p1 external_ids:iface-id=lsp
 check ovs-vsctl add-port br-int p2 -- set interface p2 external_ids:iface-id=lsp2
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 dnl Ensure the LBs are not translated to OpenFlow.
 as hv1
@@ -36306,7 +36306,7 @@  ovn-nbctl lsp-set-options lp requested-chassis=hv1
 ovs-vsctl -- add-port br-int vif -- \
     set interface vif external-ids:iface-id=lp
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # the file is read once at startup so it's safe to write it
 # here after the first ovn-controller has started
@@ -36331,7 +36331,7 @@  ovn-nbctl lsp-set-options lp2 requested-chassis=hv2
 ovs-vsctl -- add-port br-int-2 vif2 -- \
     set interface vif2 external-ids:iface-id=lp2
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # check that both tunnel ports are present, meaning controllers
 # don't step on each other
@@ -36563,7 +36563,7 @@  send_arp() {
 }
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # now start the second virtual controller
 ovs-vsctl add-br br-phys-2
@@ -36595,7 +36595,7 @@  ovs-vsctl -- add-port br-int-2 vif2 -- \
     options:rxq_pcap=hv1/vif2-rx.pcap
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVN_POPULATE_ARP
 
@@ -36631,7 +36631,7 @@  check ovn-nbctl lsp-add sw lsp1
 check ovs-vsctl add-port br-int p1 -- set interface p1 external_ids:iface-id=lsp1
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 check ovn-nbctl lb-add lb1 "192.168.0.10" "192.168.10.10,192.168.10.20" \
     -- set load_balancer lb1 options:ct_flush="true"
@@ -36834,7 +36834,7 @@  start_virtual_controller n1 br-phys-2 br-int-2 192.168.0.2 24 geneve,vxlan hv2 \
 pidfile="$OVS_RUNDIR"/ovn-controller-2.pid
 on_exit "test -e \"$pidfile\" && kill \`cat \"$pidfile\"\`"
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 check_tunnel_port() {
     local hv=$1
@@ -37344,7 +37344,7 @@  check ovn-nbctl --wait=sb lsp-del lsp1
 wake_up_controller hv-1
 
 # Make sure ovn-controller is still OK
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([test $(as hv-1 ovs-vsctl list qos | grep -c linux-htb) -eq 1])
 OVN_CLEANUP([hv-1],[hv-2])
 AT_CLEANUP
@@ -37478,7 +37478,7 @@  check ovn-nbctl lsp-set-options sw0-lr0 router-port=lr0-sw0
 check ovn-appctl -t ovn-controller vlog/set dbg:ct_zone
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 get_zone_num () {
     output=$1
@@ -37724,7 +37724,7 @@  check ovn-nbctl lsp-set-addresses sw0-lr0 00:00:00:00:ff:01
 check ovn-nbctl lsp-set-options sw0-lr0 router-port=lr0-sw0
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 hv1_ch_uuid=`ovn-sbctl --bare --columns _uuid find chassis name="hv1"`
 
 # Try to bind sw0-vir directly to an OVS port. This should be ignored by
@@ -37751,7 +37751,7 @@  sleep_controller hv1
 as hv1 ovs-vsctl del-port hv1-vif3
 
 wake_up_sb
-ovn-nbctl --wait=sb sync
+check ovn-nbctl --wait=sb sync
 wake_up_controller hv1
 check ovn-nbctl --wait=hv sync
 
@@ -38580,7 +38580,7 @@  check ovn-nbctl set Logical_Switch_Port lsp1 \
 
 as hv2
 check ovs-vsctl set Interface vif1 external-ids:iface-id=lsp1
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 wait_for_ports_up lsp1
 wait_for_ports_up sw0-port1.1
@@ -39273,7 +39273,7 @@  for hv in hv1 hv2; do
 done
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVS_WAIT_UNTIL([test $(as hv2 ovs-ofctl dump-flows br-int table=OFTABLE_OUTPUT_LARGE_PKT_DETECT | grep -c check_pkt_larger) -eq 0])
 
@@ -39658,7 +39658,7 @@  check_patch_ports \
 # ovn-controller should delete the patch ports now as we are setting
 # OVN as its owner.
 check ovs-vsctl set port patch-br-int-to-br-eth0 external_ids:ovn-localnet-port=foo
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 AS_BOX([Checking for patch ports after setting external_ids:ovn-localnet-port to the manually created patch port])
 check_patch_ports
diff --git a/tests/perf-northd.at b/tests/perf-northd.at
index 6d651b7e5..515b88244 100644
--- a/tests/perf-northd.at
+++ b/tests/perf-northd.at
@@ -17,7 +17,7 @@  m4_define([CACHE_NBDB],[
 m4_define([MEASURE_RECOMPUTE],[
     PERF_RECORD_START(Measure northd recompute)
     ovn-appctl -t northd/ovn-northd inc-engine/recompute
-    ovn-nbctl --wait=sb sync
+    check ovn-nbctl --wait=sb sync
     PERF_RECORD_STOP()
 ])
 
@@ -42,7 +42,7 @@  m4_define([BUILD_NBDB],[
         ovn-appctl -t ovn-nb/ovsdb-server ovsdb-server/remove-db OVN_Northbound
         ovn-appctl -t ovn-nb/ovsdb-server ovsdb-server/add-db ${at_suite_dir}/cached/${at_group}/ovn-nb.db
     fi
-    ovn-nbctl --wait=sb sync
+    check ovn-nbctl --wait=sb sync
     PERF_RECORD_STOP()
 
     MEASURE_RECOMPUTE()
diff --git a/tests/system-ovn-kmod.at b/tests/system-ovn-kmod.at
index 75ecdadeb..521d2ede9 100644
--- a/tests/system-ovn-kmod.at
+++ b/tests/system-ovn-kmod.at
@@ -111,7 +111,7 @@  NETNS_DAEMONIZE([foo1], [nc -l -k 192.168.1.2 80], [nc-foo1.pid])
 NETNS_DAEMONIZE([bar1], [nc -l -k 192.168.2.2 80], [nc-bar1.pid])
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Get the OF table numbers
 dnat=$(ovn-debug lflow-stage-to-oftable lr_in_dnat)
@@ -407,7 +407,7 @@  ovn-nbctl lr-lb-add R2 lb0-no-aff
 ovn-nbctl lr-lb-add R2 lb10-no-aff
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Get the OF table numbers
 dnat=$(ovn-debug lflow-stage-to-oftable lr_in_dnat)
diff --git a/tests/system-ovn.at b/tests/system-ovn.at
index 6dfc3055a..f647f5760 100644
--- a/tests/system-ovn.at
+++ b/tests/system-ovn.at
@@ -98,7 +98,7 @@  ovn-nbctl -- --id=@nat create nat type="snat" logical_ip=192.168.2.2 \
     external_ip=30.0.0.1 -- add logical_router R2 nat @nat
 
 # wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=30.0.0.1)'])
 
 # 'alice1' should be able to ping 'foo1' directly.
@@ -137,7 +137,7 @@  icmp,orig=(src=192.168.2.2,dst=172.16.1.2,id=<cleared>,type=8,code=0),reply=(src
 ovn-nbctl lr-route-add R1 30.0.0.0/24 20.0.0.2
 
 # wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Flush conntrack entries for easier output parsing of next test.
 AT_CHECK([ovs-appctl dpctl/flush-conntrack])
@@ -278,7 +278,7 @@  ovn-nbctl -- --id=@nat create nat type="snat" logical_ip=\"fd12::2\" \
     external_ip=\"fd30::1\" -- add logical_router R2 nat @nat
 
 # wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=fd30::1)'])
 
 # 'alice1' should be able to ping 'foo1' directly.
@@ -317,7 +317,7 @@  icmpv6,orig=(src=fd12::2,dst=fd21::2,id=<cleared>,type=128,code=0),reply=(src=fd
 ovn-nbctl lr-route-add R1 fd30::/64 fd00::2
 
 # wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Flush conntrack entries for easier output parsing of next test.
 AT_CHECK([ovs-appctl dpctl/flush-conntrack])
@@ -438,7 +438,7 @@  ovn-nbctl lsp-add alice alice1 \
 ovn-nbctl -- --id=@nat create nat type="snat" logical_ip=192.168.1.2 \
     external_ip=172.16.1.1 -- add logical_router R2 nat @nat
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=172.16.1.1)'])
 
 # South-North SNAT: 'foo1' pings 'alice1'. But 'alice1' receives traffic
@@ -550,7 +550,7 @@  ovn-nbctl lsp-add alice alice1 \
 ovn-nbctl -- --id=@nat create nat type="snat" logical_ip=\"fd10::2\" \
     external_ip=\"fd30::1\" -- add logical_router R2 nat @nat
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=fd30::1)'])
 
 # South-North SNAT: 'foo1' pings 'alice1'. But 'alice1' receives traffic
@@ -723,7 +723,7 @@  ovn-nbctl -- --id=@nat create nat type="snat" logical_ip=192.168.2.2 \
     external_ip=30.0.0.4 -- add logical_router R3 nat @nat
 
 # wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=30.0.0.4)'])
 
 # North-South DNAT: 'alice1' should be able to ping 'foo1' via 30.0.0.2
@@ -949,7 +949,7 @@  ovn-nbctl -- --id=@nat create nat type="snat" logical_ip='"fd12::2"' \
     external_ip='"fd40::4"' -- add logical_router R3 nat @nat
 
 # wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=fd40::4)'])
 
 # North-South DNAT: 'alice1' should be able to ping 'foo1' via fd30::2
@@ -1210,7 +1210,7 @@  ovn-nbctl -- --id=@nat create nat type="snat" logical_ip='"fd12::2"' \
     external_ip='"fd40::4"' -- add logical_router R3 nat @nat
 
 # wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=fd40::4)'])
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=30.0.0.4)'])
 
@@ -1426,7 +1426,7 @@  ovn-nbctl ls-lb-add foo lb2
 ovn-nbctl set load_balancer $lb2_uuid vips:'"30.0.0.2:8000"'='"172.16.1.2:80,172.16.1.3:80,172.16.1.4:80"'
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=172.16.1.4:80)'])
 
@@ -1445,7 +1445,7 @@  AT_CHECK([ovs-appctl dpctl/flush-conntrack])
 
 # Clear the apply-after-lb option.  The traffic will be allowed.
 check ovn-nbctl clear acl . options
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVS_WAIT_FOR_OUTPUT([
     for i in `seq 1 20`; do
@@ -1459,7 +1459,7 @@  tcp,orig=(src=192.168.1.2,dst=30.0.0.1,sport=<cleared>,dport=<cleared>),reply=(s
 ])
 
 ovn-nbctl acl-del foo from-lport 1002 "ip4 && ip4.dst == {172.16.1.2,172.16.1.3,172.16.1.4} && ct.new"
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 dnl Should work with the virtual IP 30.0.0.1 address through NAT
 dnl Each server should have at least one connection.
@@ -1707,7 +1707,7 @@  ovn-nbctl add logical_switch foo load_balancer $lb2_uuid
 ovn-nbctl set load_balancer $lb2_uuid vips:'"[[fd03::2]]:8000"'='"@<:@fd02::2@:>@:80,@<:@fd02::3@:>@:80,@<:@fd02::4@:>@:80"'
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=\[[fd02::4\]]:80)'])
 
@@ -1902,7 +1902,7 @@  ovn-nbctl set logical_switch foo load_balancer=$uuid
 ovn-nbctl set load_balancer $uuid vips:'"30.0.0.2:8000"'='"192.168.1.3:80,192.168.1.4:80,192.168.1.5:80"'
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=192.168.1.5:80)'])
 
@@ -2012,7 +2012,7 @@  ovn-nbctl set load_balancer $uuid vips:'"[[fd03::2]]:8000"'='"@<:@fd01::3@:>@:80
 ovn-nbctl list load_balancer
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=\[[fd01::5\]]:80)'])
 
@@ -2166,7 +2166,7 @@  ovn-nbctl -- --id=@nat create nat type="snat" logical_ip=192.168.2.2 \
     external_ip=30.0.0.2 -- add logical_router R2 nat @nat
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Get the OF table numbers
 snat=$(ovn-debug lflow-stage-to-oftable lr_out_snat)
@@ -2516,7 +2516,7 @@  ovn-nbctl -- --id=@nat create nat type="snat" logical_ip=\"fd12::2\" \
 
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=\[[fd12::2\]]:80)'])
 
@@ -2694,7 +2694,7 @@  ovn-nbctl set logical_router R2 load_balancer=$uuid
 ovn-nbctl set logical_router R3 load_balancer=$uuid
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=192.168.2.2)'])
 
@@ -2867,7 +2867,7 @@  ovn-nbctl set logical_router R2 load_balancer=$uuid
 ovn-nbctl set logical_router R3 load_balancer=$uuid
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=fd12::2)'])
 
@@ -3074,7 +3074,7 @@  ovn-nbctl set logical_router R2 load_balancer=$uuid
 ovn-nbctl set logical_router R3 load_balancer=$uuid
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=192.168.2.2)'])
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
@@ -3222,7 +3222,7 @@  ovn-nbctl set logical_router R1 load_balancer=$uuid
 ovn-nbctl set load_balancer $uuid vips:'"172.16.1.11:8000"'='"192.168.1.2:80,192.168.2.2:80"'
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=192.168.2.2:80)'])
 
@@ -3365,7 +3365,7 @@  ovn-nbctl set logical_router R1 load_balancer=$uuid
 ovn-nbctl set load_balancer $uuid vips:'"[[fd72::11]]:8000"'='"@<:@fd01::2@:>@:80,@<:@fd02::2@:>@:80"'
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=\[[fd02::2\]]:80)'])
 
@@ -3523,7 +3523,7 @@  AT_CHECK([ovn-nbctl lr-nat-add R1 snat 172.16.1.1 0.0.0.0/0])
 # Add default route to ext-net
 AT_CHECK([ovn-nbctl lr-route-add R1 10.0.0.0/24 172.16.1.2])
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=172.16.1.1)'])
 
 # North-South DNAT: 'alice1' pings 'foo1' using 172.16.1.3.
@@ -3717,7 +3717,7 @@  ADD_VETH(alice1, alice1, br-int, "fd20::2/64", "f0:00:00:01:02:05", \
 ovn-nbctl lsp-add alice alice1 \
 -- lsp-set-addresses alice1 "f0:00:00:01:02:05 fd20::2"
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Add DNAT rules
 AT_CHECK([ovn-nbctl lr-nat-add R1 dnat_and_snat fd20::3 fd11::2 foo1 00:00:02:02:03:04])
@@ -3726,7 +3726,7 @@  AT_CHECK([ovn-nbctl lr-nat-add R1 dnat_and_snat fd20::4 fd11::3 foo2 00:00:02:02
 # Add a SNAT rule
 AT_CHECK([ovn-nbctl lr-nat-add R1 snat fd20::1 ::/0])
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=fd20::1)'])
 
 # North-South DNAT: 'alice1' pings 'foo1' using fd20::3
@@ -3921,7 +3921,7 @@  AT_CHECK([ovn-nbctl lr-nat-add R1 dnat_and_snat 172.16.1.4 192.168.2.2 bar1 00:0
 # Add a SNAT rule
 AT_CHECK([ovn-nbctl lr-nat-add R1 snat 172.16.1.1 0.0.0.0/0])
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=172.16.1.1)'])
 
 echo "------ hv dump ------"
@@ -4105,7 +4105,7 @@  AT_CHECK([ovn-nbctl lr-nat-add R1 dnat_and_snat fd20::4 fd12::2 bar1 00:00:02:02
 # Add a SNAT rule
 AT_CHECK([ovn-nbctl lr-nat-add R1 snat fd20::1 ::/0])
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl dump-flows br-int | grep 'nat(src=fd20::1)'])
 
 echo "------ hv dump ------"
@@ -4222,7 +4222,7 @@  ovn-nbctl lsp-add ls1 p1 \
 ovn-nbctl lsp-add ls1 p2 \
 -- lsp-set-addresses p2 "00:00:00:00:00:20 192.168.1.20"
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 zone_id=$(ovn-appctl -t ovn-controller ct-zone-list | grep p1 | cut -d ' ' -f2)
 
@@ -4318,7 +4318,7 @@  done
 # Enable IGMP snooping on sw1.
 ovn-nbctl set Logical_Switch sw1 other_config:mcast_querier="false"
 ovn-nbctl set Logical_Switch sw1 other_config:mcast_snoop="true"
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 group_v4="239.0.1.68"
 # Inject IGMP Join for v4 group on sw1-p1.
@@ -4348,7 +4348,7 @@  OVS_WAIT_UNTIL([
 
 # Flush IGMP groups.
 ovn-sbctl ip-multicast-flush sw1
-ovn-nbctl --wait=hv -t 3 sync
+check ovn-nbctl --wait=hv -t 3 sync
 OVS_WAIT_UNTIL([
     total_entries=`ovn-sbctl find IGMP_Group address="${group_v4}" | grep _uuid -c`
     test "${total_entries}" = "0"
@@ -4510,7 +4510,7 @@  ovn-nbctl --wait=sb ls-lb-add sw1 lb1
 ovn-nbctl --wait=sb lr-lb-add lr0 lb1
 
 OVN_POPULATE_ARP
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ADD_NAMESPACES(sw0-p1)
 ADD_VETH(sw0-p1, sw0-p1, br-int, "10.0.0.3/24", "50:54:00:00:00:03", \
@@ -4736,7 +4736,7 @@  check ovn-nbctl ls-lb-add sw1 lb1
 check ovn-nbctl lr-lb-add lr0 lb1
 
 OVN_POPULATE_ARP
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ADD_NAMESPACES(sw0-p1)
 ADD_VETH(sw0-p1, sw0-p1, br-int, "2001::3/64", "50:54:00:00:00:03", \
@@ -4882,7 +4882,7 @@  ADD_NAMESPACES(lsp)
 ADD_VETH(lsp, lsp, br-int, "42.42.42.1/24", "00:00:00:00:00:01", \
          "42.42.42.254")
 
-ovn-nbctl --wait=hv -t 3 sync
+check ovn-nbctl --wait=hv -t 3 sync
 
 # Start IPv4 TCP server on lsp.
 NETNS_DAEMONIZE([lsp], [nc -l -k 42.42.42.1 4041], [lsp0.pid])
@@ -4911,7 +4911,7 @@  ovn-nbctl pg-add pg0 lsp
 ovn-nbctl --apply-after-lb acl-add pg0 from-lport 1004 "ip4 && ip4.dst == 10.0.0.2" drop
 ovn-nbctl --apply-after-lb acl-add pg0 from-lport 1002 "ip4 && tcp" allow-related
 ovn-nbctl --apply-after-lb acl-add pg0 from-lport 1002 "ip4 && udp" allow
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ## Check that IPv4 TCP hairpin connection succeeds on both VIPs.
 NS_CHECK_EXEC([lsp], [nc 88.88.88.88 8080 -z], [0], [ignore], [ignore])
@@ -4979,7 +4979,7 @@  ovn-nbctl lsp-add sw sw-rtr                       \
 
 ADD_NAMESPACES(lsp)
 ADD_VETH(lsp, lsp, br-int, "4200::1/64", "00:00:00:00:00:01", "4200::00ff", "nodad")
-ovn-nbctl --wait=hv -t 3 sync
+check ovn-nbctl --wait=hv -t 3 sync
 
 # Start IPv6 TCP server on lsp.
 NETNS_DAEMONIZE([lsp], [nc -l -k 4200::1 4041], [lsp0.pid])
@@ -5008,7 +5008,7 @@  ovn-nbctl pg-add pg0 lsp
 ovn-nbctl --apply-after-lb acl-add pg0 from-lport 1002 "ip6 && tcp" allow-related
 ovn-nbctl --apply-after-lb acl-add pg0 from-lport 1002 "ip6 && udp" allow
 ovn-nbctl --apply-after-lb acl-add pg0 from-lport 1000 "ip6" drop
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Check that IPv6 TCP hairpin connection succeeds on both VIPs.
 NS_CHECK_EXEC([lsp], [nc 8800::0088 8080 -z], [0], [ignore], [ignore])
@@ -5096,7 +5096,7 @@  ovn-nbctl lsp-set-addresses sw1-lr0 router
 ovn-nbctl lsp-set-options sw1-lr0 router-port=lr0-sw1
 
 OVN_POPULATE_ARP
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ADD_NAMESPACES(sw0-p1-rej)
 ADD_VETH(sw0-p1-rej, sw0-p1-rej, br-int, "10.0.0.3/24", "50:54:00:00:00:03", \
@@ -5330,7 +5330,7 @@  ovn-nbctl lsp-set-addresses sw1-lr0 router
 ovn-nbctl lsp-set-options sw1-lr0 router-port=lr0-sw1
 
 OVN_POPULATE_ARP
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ADD_NAMESPACES(sw0-p1-rej)
 ADD_VETH(sw0-p1-rej, sw0-p1-rej, br-int, "10.0.0.3/24", "50:54:00:00:00:03", \
@@ -5577,7 +5577,7 @@  ovn-nbctl --wait=sb ls-lb-add sw0 lb1
 ovn-nbctl --wait=sb lr-lb-add lr0 lb1
 
 OVN_POPULATE_ARP
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ADD_NAMESPACES(rst-p1)
 ADD_VETH(rst-p1, rst-p1, br-int, "10.0.0.3/24", "50:54:00:00:00:03", \
@@ -6154,7 +6154,7 @@  ovn-nbctl lsp-add bob bob1 \
 -- lsp-set-addresses bob1 "f0:00:00:01:02:06 172.16.0.1"
 
 # Ensure ovn-controller is caught up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 on_exit 'ovs-ofctl dump-flows br-int'
 
@@ -6193,7 +6193,7 @@  ovn-nbctl set Logical_Switch_Port r2-ext \
      type=router options:router-port=R2_ext addresses='"00:00:10:01:02:04"'
 
 # Wait for ovn-controller before sending traffic
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 NS_CHECK_EXEC([bob1], [nc -z 10.0.0.2 80], [0])
 NS_CHECK_EXEC([bob1], [ping -q -c 3 -i 0.3 -w 2 10.0.0.2 | FORMAT_PING], \
@@ -6388,7 +6388,7 @@  ovn-nbctl lsp-add bob bob1 \
 -- lsp-set-addresses bob1 "f0:00:00:01:02:06 fd07::1"
 
 # Ensure ovn-controller is caught up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 on_exit 'ovs-ofctl dump-flows br-int'
 
@@ -6613,7 +6613,7 @@  ovn-nbctl lsp-add public public1 \
         -- lsp-set-type public1 localnet \
         -- lsp-set-options public1 network_name=phynet
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Send ping from sw01-x to ext-foo.
 NS_CHECK_EXEC([sw01-x], [ping -q -c 3 -i 0.3 -w 2 172.16.1.100 | FORMAT_PING], \
@@ -7120,7 +7120,7 @@  check ovn-nbctl acl-add pg1 from-lport 1002 "ip" allow-related
 check ovn-nbctl acl-add pg1 to-lport 1002 "ip" allow-related
 
 OVN_POPULATE_ARP
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ADD_NAMESPACES(sw0-p1)
 ADD_VETH(sw0-p1, sw0-p1, br-int, "10.0.0.3/24", "50:54:00:00:00:03", \
@@ -7277,7 +7277,7 @@  ovn-nbctl lr-route-add lr1 0.0.0.0/0 172.18.1.2
 #ovn-sbctl create MAC_Binding ip=172.18.2.10 datapath=$ls1_uuid logical_port=vm2 mac="00:00:00:00:00:06"
 
 OVN_POPULATE_ARP
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 ADD_NAMESPACES(vm1)
 ADD_VETH(vm1, vm1, br-int, "192.168.100.5/24", "00:00:00:00:00:05", \
@@ -7723,7 +7723,7 @@  ADD_VETH(sw0-p3, sw0-p3, br-int, "10.0.0.4/24", "50:54:00:00:00:04", \
          "10.0.0.1")
 
 # Ensure ovn-controller is caught up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 on_exit 'ovn-nbctl acl-list sw0'
 on_exit 'ovn-sbctl lflow-list'
@@ -7865,7 +7865,7 @@  ADD_VETH(sw0-p3, sw0-p3, br-int, "10.0.0.4/24", "50:54:00:00:00:04", \
          "10.0.0.1")
 
 # Ensure ovn-controller is caught up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 on_exit 'ovn-nbctl acl-list sw0'
 on_exit 'ovn-sbctl lflow-list'
@@ -7993,7 +7993,7 @@  ADD_VETH(sw0-p2, sw0-p2, br-int, "10.0.0.3/24", "50:54:00:00:00:03", \
          "10.0.0.1")
 
 # Ensure ovn-controller is caught up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 on_exit 'ovn-nbctl acl-list sw0'
 on_exit 'ovn-sbctl lflow-list'
@@ -8020,7 +8020,7 @@  icmp,orig=(src=10.0.0.2,dst=10.0.0.3,id=<cleared>,type=8,code=0),reply=(src=10.0
 # This ACL also allows the ping running in background.
 
 check ovn-nbctl --label=1235 acl-add sw0 from-lport 1003 'ip4 && inport == "sw0-p1" && ip4.dst == 10.0.0.3' allow-related
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 sleep 3s
 
@@ -8094,7 +8094,7 @@  ADD_VETH(sw0-p2, sw0-p2, br-int, "10.0.0.3/24", "50:54:00:00:00:03", \
          "10.0.0.1")
 
 # Ensure ovn-controller is caught up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 on_exit 'ovn-nbctl acl-list sw0'
 on_exit 'ovn-sbctl lflow-list'
@@ -8121,7 +8121,7 @@  icmp,orig=(src=10.0.0.2,dst=10.0.0.3,id=<cleared>,type=8,code=0),reply=(src=10.0
 # This ACL also allows the ping running in background.
 
 check ovn-nbctl --label=1235 --apply-after-lb acl-add sw0 from-lport 1003 'ip4 && inport == "sw0-p1" && ip4.dst == 10.0.0.3' allow-related
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 sleep 3s
 
@@ -8212,7 +8212,7 @@  check ovn-nbctl lsp-set-addresses sw1-lr0 00:00:00:00:ff:02
 check ovn-nbctl lsp-set-options sw1-lr0 router-port=lr0-sw1
 
 # Ensure ovn-controller is caught up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 on_exit 'ovn-nbctl acl-list sw0'
 on_exit 'ovn-sbctl lflow-list'
@@ -9772,7 +9772,7 @@  ovn-nbctl lb-add lb1 30.30.30.30:80 "192.168.2.2:80" tcp
 ovn-nbctl ls-lb-add foo lb1
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=192.168.2.2:80)'])
@@ -9825,7 +9825,7 @@  AT_CHECK([ovs-appctl dpctl/flush-conntrack])
 ovn-nbctl ls-lb-add foo lb1
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=192.168.2.2:80)'])
@@ -9917,7 +9917,7 @@  ovn-nbctl lb-add lb1 [[fd30::2]]:80 [[fd12::2]]:80 tcp
 ovn-nbctl ls-lb-add foo lb1
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=\[[fd12::2\]]:80)'])
@@ -9969,7 +9969,7 @@  AT_CHECK([ovs-appctl dpctl/flush-conntrack])
 ovn-nbctl ls-lb-add foo lb1
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=\[[fd12::2\]]:80)'])
@@ -10338,7 +10338,7 @@  check ovn-nbctl ls-lb-add foo lb2
 check ovn-nbctl set load_balancer $lb2_uuid vips:'"30.0.0.2:8000"'='"172.16.1.2:80,172.16.1.3:80,172.16.1.4:80"'
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=172.16.1.4:80)'])
 
@@ -12094,7 +12094,7 @@  ovn-nbctl -- --id=@nat create nat type="snat" logical_ip=192.168.2.2 \
     external_ip=30.0.0.2 -- add logical_router R2 nat @nat
 
 # Wait for ovn-controller to catch up.
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 OVS_WAIT_UNTIL([ovs-ofctl -O OpenFlow13 dump-groups br-int | \
 grep 'nat(dst=192.168.2.2:12345)'])
 
@@ -12533,7 +12533,7 @@  check ovn-nbctl lsp-set-addresses lp0 "50:54:00:00:00:01 10.0.0.10"
 check ovn-nbctl lsp-set-addresses lp1 "50:54:00:00:00:02 20.0.0.10"
 
 OVS_WAIT_UNTIL([test x`ovn-nbctl lsp-get-up lp0` = xup])
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 # Stopping updates to sb
 # By stopping temporarily updates from controller to sb, we are making sb read-only.
@@ -13213,7 +13213,7 @@  ovs-vsctl --id=@br get Bridge br-int \
     -- --id=@ipfix create IPFIX targets=\"127.0.0.1:4242\" template_interval=1 \
     -- --id=@cs create Flow_Sample_Collector_Set id=100 bridge=@br ipfix=@ipfix
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 dnl And wait for it to be up and running.
 OVS_WAIT_UNTIL([ovs-ofctl dump-ipfix-flow br-int | grep -q '1 ids'])
 
@@ -13382,7 +13382,7 @@  ovs-vsctl --id=@br get Bridge br-int \
     -- --id=@ipfix create IPFIX targets=\"127.0.0.1:4242\" template_interval=1 \
     -- --id=@cs create Flow_Sample_Collector_Set id=100 bridge=@br ipfix=@ipfix
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 dnl And wait for it to be up and running.
 OVS_WAIT_UNTIL([ovs-ofctl dump-ipfix-flow br-int | grep -q '1 ids'])
 
@@ -13512,7 +13512,7 @@  ovs-vsctl --id=@br get Bridge br-int \
     -- --id=@ipfix create IPFIX targets=\"127.0.0.1:4242\" template_interval=1 \
     -- --id=@cs create Flow_Sample_Collector_Set id=100 bridge=@br ipfix=@ipfix
 
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 dnl And wait for it to be up and running.
 OVS_WAIT_UNTIL([ovs-ofctl dump-ipfix-flow br-int | grep -q '1 ids'])
 
@@ -13973,7 +13973,7 @@  ensure_controller_run
 restart_ovsdb_controller_updates $TCP_PORT
 
 wait_for_ports_up
-ovn-nbctl --wait=hv sync
+check ovn-nbctl --wait=hv sync
 
 AT_CHECK([ovn-appctl -t ovn-controller ct-zone-list | sed "s/ [[0-9]]*/ ??/" | sort], [0], [dnl
 sw0-port1 ??