diff mbox series

[ovs-dev] tests: Fix Port_Binding up test.

Message ID 2BAB7EDD-BBE4-4113-9878-DE65B55B8F37@tencent.com
State Accepted
Headers show
Series [ovs-dev] tests: Fix Port_Binding up test. | expand

Commit Message

gmingchen(陈供明) Feb. 7, 2021, 2:52 a.m. UTC
From: Gongming Chen <gmingchen@tencent.com>

After setting the iface-id, immediately check the up status of the port
binding, it will occasionally fail, especially when the port binding
status is reported later.

When it fails, the following will be output:
Checking values in sb Port_Binding with logical_port=lsp1 against false... found false
ovs-vsctl add-port br-int lsp1 -- set Interface lsp1 external-ids:iface-id=lsp1
./ovn-macros.at:307: "$@"
Checking values in sb Port_Binding with logical_port=lsp1 against true... found false
_uuid               : 15ebabb6-3dbb-4806-aa85-d1c03e3b39f6
logical_port        : lsp1
up                  : true
./ovn-macros.at:393: hard failure

Fixes: 4d3cb42b076b ("binding: Set Logical_Switch_Port.up when all OVS flows are installed.")
Signed-off-by: Gongming Chen <gmingchen@tencent.com>
---
 tests/ovn.at | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Dumitru Ceara Feb. 8, 2021, 9:09 a.m. UTC | #1
On 2/7/21 3:52 AM, gmingchen(陈供明) wrote:
> From: Gongming Chen <gmingchen@tencent.com>
> 
> After setting the iface-id, immediately check the up status of the port
> binding, it will occasionally fail, especially when the port binding
> status is reported later.
> 
> When it fails, the following will be output:
> Checking values in sb Port_Binding with logical_port=lsp1 against false... found false
> ovs-vsctl add-port br-int lsp1 -- set Interface lsp1 external-ids:iface-id=lsp1
> ./ovn-macros.at:307: "$@"
> Checking values in sb Port_Binding with logical_port=lsp1 against true... found false
> _uuid               : 15ebabb6-3dbb-4806-aa85-d1c03e3b39f6
> logical_port        : lsp1
> up                  : true
> ./ovn-macros.at:393: hard failure
> 
> Fixes: 4d3cb42b076b ("binding: Set Logical_Switch_Port.up when all OVS flows are installed.")
> Signed-off-by: Gongming Chen <gmingchen@tencent.com>
> ---

Thanks for the fix!

Acked-by: Dumitru Ceara <dceara@redhat.com>
Numan Siddique Feb. 8, 2021, 10:01 a.m. UTC | #2
On Mon, Feb 8, 2021 at 2:40 PM Dumitru Ceara <dceara@redhat.com> wrote:
>
> On 2/7/21 3:52 AM, gmingchen(陈供明) wrote:
> > From: Gongming Chen <gmingchen@tencent.com>
> >
> > After setting the iface-id, immediately check the up status of the port
> > binding, it will occasionally fail, especially when the port binding
> > status is reported later.
> >
> > When it fails, the following will be output:
> > Checking values in sb Port_Binding with logical_port=lsp1 against false... found false
> > ovs-vsctl add-port br-int lsp1 -- set Interface lsp1 external-ids:iface-id=lsp1
> > ./ovn-macros.at:307: "$@"
> > Checking values in sb Port_Binding with logical_port=lsp1 against true... found false
> > _uuid               : 15ebabb6-3dbb-4806-aa85-d1c03e3b39f6
> > logical_port        : lsp1
> > up                  : true
> > ./ovn-macros.at:393: hard failure
> >
> > Fixes: 4d3cb42b076b ("binding: Set Logical_Switch_Port.up when all OVS flows are installed.")
> > Signed-off-by: Gongming Chen <gmingchen@tencent.com>
> > ---
>
> Thanks for the fix!
>
> Acked-by: Dumitru Ceara <dceara@redhat.com>

Thanks for the fix. I applied this patch to master.

I also added your name to the AUTHORS list.

Numan

>
> _______________________________________________
> dev mailing list
> dev@openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
diff mbox series

Patch

diff --git a/tests/ovn.at b/tests/ovn.at
index 80c9fe138..43dc16dd8 100644
--- a/tests/ovn.at
+++ b/tests/ovn.at
@@ -23885,7 +23885,7 @@  check ovn-nbctl --wait=hv sync
 check_column "false" Port_Binding up logical_port=lsp1

 check ovs-vsctl add-port br-int lsp1 -- set Interface lsp1 external-ids:iface-id=lsp1
-check_column "true" Port_Binding up logical_port=lsp1
+wait_column "true" Port_Binding up logical_port=lsp1
 wait_column "true" nb:Logical_Switch_Port up name=lsp1
 OVS_WAIT_UNTIL([test `ovs-vsctl get Interface lsp1 external_ids:ovn-installed` = '"true"'])