From patchwork Tue Nov 5 19:23:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Bianconi X-Patchwork-Id: 2007117 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=S6pg5Krt; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.137; helo=smtp4.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=patchwork.ozlabs.org) Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4XjdYy1kQgz1xyR for ; Wed, 6 Nov 2024 06:24:22 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 9A6E440648; Tue, 5 Nov 2024 19:24:19 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id 1q25ttMJIjZi; Tue, 5 Nov 2024 19:24:16 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=140.211.9.56; helo=lists.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver= DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org DEE4B40623 Authentication-Results: smtp4.osuosl.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=S6pg5Krt Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp4.osuosl.org (Postfix) with ESMTPS id DEE4B40623; Tue, 5 Nov 2024 19:24:14 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 7FF8BC08A6; Tue, 5 Nov 2024 19:24:14 +0000 (UTC) X-Original-To: ovs-dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by lists.linuxfoundation.org (Postfix) with ESMTP id 229ABC08BC for ; Tue, 5 Nov 2024 19:24:13 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 0C7F240568 for ; Tue, 5 Nov 2024 19:24:01 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id E-YrFHvk6F-r for ; Tue, 5 Nov 2024 19:23:59 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=170.10.133.124; helo=us-smtp-delivery-124.mimecast.com; envelope-from=lorenzo.bianconi@redhat.com; receiver= DMARC-Filter: OpenDMARC Filter v1.4.2 smtp4.osuosl.org 643EF4052B Authentication-Results: smtp4.osuosl.org; dmarc=pass (p=none dis=none) header.from=redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 643EF4052B Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by smtp4.osuosl.org (Postfix) with ESMTPS id 643EF4052B for ; Tue, 5 Nov 2024 19:23:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1730834636; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=dqtDEsIx3WeeT9ptezrw6czQJt1CNZFj1nZBKIDAt0w=; b=S6pg5Krt8ADw76PAmjd9VqomQ4+V7dcViSFNunDDGdRAKGpzmWMmoPhRJTYXG+gLzS/X6z 7nqG/vOsidaqoAPw3Cb2OkzX8ZXko37lXSsVQDYigYXCokB7CadGlG2sq34i/IVI2GtvET tZD65OdLdHGiOCb9WvDvftE4+vBV3ug= Received: from mail-oa1-f72.google.com (mail-oa1-f72.google.com [209.85.160.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-438-PFa8C02vOF-J-lGOx1Lr7A-1; Tue, 05 Nov 2024 14:23:55 -0500 X-MC-Unique: PFa8C02vOF-J-lGOx1Lr7A-1 Received: by mail-oa1-f72.google.com with SMTP id 586e51a60fabf-28f4d9c29bfso3634506fac.1 for ; Tue, 05 Nov 2024 11:23:55 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730834634; x=1731439434; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dqtDEsIx3WeeT9ptezrw6czQJt1CNZFj1nZBKIDAt0w=; b=RBvvWzsG3vdcbEP/1OaSfP2rA2uMS6lH9HJM+8VaaUcGZ+zqtb5YMa/VnKsMjiHbDd 9QQ2bksArGOsBXMfHQNZIFVYt3Mn8u0+twonHm0IIljg/bB8HG+rM7Tg2Tldw41Himpq uarPS1chwK6e+QFDS0GVzuJz3jVz+yi91LFbWoJvKc4Vb0EOv1bWJzPLP0Zl0GYfg+p5 mUX1PFkMv4FpZMrDX+mvvRaSlWYjreAE32ikvf+f6kMeWr1l7Qeg+qNOxQdXRhZM03/e ydFjk4PPLSCQ1bz3QKt4KWwFg40tja9n5EEIkWDL1v2eCd/3vc9mEvVYn1weHYX+LCKW ndMQ== X-Gm-Message-State: AOJu0YzHBHAUsZyf55Wcio4j4GYsjJ57HyBp9SdvSm01ZSf6mc/HZPxF umF4jeD4T8czlVCrGassQ3MJ0JcJzfpT1g8DgDqSmv98m2GAhKzzb/EUmVVrRWu2vVIBT8zBpFj bU4kvQC299aSa/bKPxSjL/6mkwSZI//dZZuNrT1dE93frM5ptBax0ITgx+NIiUPBm3Q2oXagcc7 wAhTJJmycIArg4LTy6mUfq0t2Yi9AHnXhw5RpHQ4GAiYkTHujeZg== X-Received: by 2002:a05:6870:3043:b0:26f:ddfa:3564 with SMTP id 586e51a60fabf-2949ed307damr16128270fac.6.1730834634178; Tue, 05 Nov 2024 11:23:54 -0800 (PST) X-Google-Smtp-Source: AGHT+IGqV/tWi2U+0wXUtx80ScmtGDn0NVvKtuhzfjy0r1Y+m1z26g12rcrfGmHFa8X5sKz57Zih4A== X-Received: by 2002:a05:6870:3043:b0:26f:ddfa:3564 with SMTP id 586e51a60fabf-2949ed307damr16128245fac.6.1730834633744; Tue, 05 Nov 2024 11:23:53 -0800 (PST) Received: from localhost (net-93-146-37-148.cust.vodafonedsl.it. [93.146.37.148]) by smtp.gmail.com with ESMTPSA id 586e51a60fabf-29487485e09sm3837739fac.14.2024.11.05.11.23.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Nov 2024 11:23:53 -0800 (PST) From: Lorenzo Bianconi To: ovs-dev@openvswitch.org Cc: i.maximets@ovn.org Date: Tue, 5 Nov 2024 20:23:28 +0100 Message-ID: <003a10562e1ad1aa97a2d9785b897df270a5749a.1730833286.git.lorenzo.bianconi@redhat.com> X-Mailer: git-send-email 2.47.0 In-Reply-To: References: MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH v2 ovn 6/8] test: ovn-ic: Use check for ovn-nbctl wherever possible. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" Reported-at: https://issues.redhat.com/browse/FDP-875 Signed-off-by: Lorenzo Bianconi --- tests/ovn-ic.at | 50 ++++++++++++++++++++++++------------------------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/tests/ovn-ic.at b/tests/ovn-ic.at index 33ad37f2e..a6463ae3a 100644 --- a/tests/ovn-ic.at +++ b/tests/ovn-ic.at @@ -15,7 +15,7 @@ availability-zone az2 ]) ovn_as az1 -ovn-nbctl set NB_Global . name=az3 +check ovn-nbctl set NB_Global . name=az3 OVS_WAIT_UNTIL([ovn-ic-sbctl show | grep -q az3]) AT_CHECK([ovn-ic-sbctl show], [0], [dnl availability-zone az2 @@ -23,7 +23,7 @@ availability-zone az3 ]) ovn_as az2 -ovn-nbctl set NB_Global . name=\"\" +check ovn-nbctl set NB_Global . name=\"\" OVS_WAIT_WHILE([ovn-ic-sbctl show | grep -q az2]) AT_CHECK([ovn-ic-sbctl show], [0], [dnl availability-zone az3 @@ -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) @@ -357,12 +357,12 @@ ovs-vsctl set open . external-ids:ovn-is-interconn=true ovn_as az1 # Create LRP and connect to TS -ovn-nbctl lr-add lr1 -ovn-nbctl lrp-add lr1 lrp-lr1-ts1 aa:aa:aa:aa:aa:01 169.254.100.1/24 -ovn-nbctl lsp-add ts1 lsp-ts1-lr1 -ovn-nbctl lsp-set-addresses lsp-ts1-lr1 router -ovn-nbctl lsp-set-type lsp-ts1-lr1 router -ovn-nbctl --wait=hv lsp-set-options lsp-ts1-lr1 router-port=lrp-lr1-ts1 +check ovn-nbctl lr-add lr1 +check ovn-nbctl lrp-add lr1 lrp-lr1-ts1 aa:aa:aa:aa:aa:01 169.254.100.1/24 +check ovn-nbctl lsp-add ts1 lsp-ts1-lr1 +check ovn-nbctl lsp-set-addresses lsp-ts1-lr1 router +check ovn-nbctl lsp-set-type lsp-ts1-lr1 router +check ovn-nbctl --wait=hv lsp-set-options lsp-ts1-lr1 router-port=lrp-lr1-ts1 OVS_WAIT_UNTIL([ovn_as az2 ovn-nbctl show | grep lsp-ts1-lr1]) ovn_as az2 ovn-nbctl lsp-set-options lsp-ts1-lr1 requested-chassis=gw1 @@ -377,20 +377,20 @@ OVS_WAIT_FOR_OUTPUT([ovn_as az2 ovn-sbctl -f csv -d bare --no-headings --columns lsp-ts1-lr1,remote ]) -ovn-nbctl lrp-set-gateway-chassis lrp-lr1-ts1 gw1 +check ovn-nbctl lrp-set-gateway-chassis lrp-lr1-ts1 gw1 OVS_WAIT_UNTIL([ovn_as az2 ovn-sbctl show | grep lsp-ts1-lr1]) ovn_as az2 ovn-nbctl lsp-set-options lsp-ts1-lr1 requested-chassis="" -ovn-nbctl lrp-del-gateway-chassis lrp-lr1-ts1 gw1 +check ovn-nbctl lrp-del-gateway-chassis lrp-lr1-ts1 gw1 OVS_WAIT_WHILE([ovn_as az2 ovn-sbctl show | grep lsp-ts1-lr1]) -ovn-nbctl set logical_router_port lrp-lr1-ts1 mac="\"aa:aa:aa:aa:aa:02\"" \ +check ovn-nbctl set logical_router_port lrp-lr1-ts1 mac="\"aa:aa:aa:aa:aa:02\"" \ networks="169.254.100.2/24 169.254.200.3/24" OVS_WAIT_UNTIL([ovn_as az2 ovn-nbctl show | grep "aa:aa:aa:aa:aa:02 169.254.100.2/24 169.254.200.3/24"]) # Delete the router port from az1, the remote port in az2 should still remain # but just lost address. -ovn-nbctl lrp-del lrp-lr1-ts1 +check ovn-nbctl lrp-del lrp-lr1-ts1 OVS_WAIT_WHILE([ovn_as az2 ovn-nbctl show | grep "aa:aa:aa:aa:aa:02 169.254.100.2/24 169.254.200.3/24"]) AT_CHECK([ovn_as az2 ovn-nbctl show | uuidfilt], [0], [dnl switch <0> (ts1) @@ -399,7 +399,7 @@ switch <0> (ts1) ]) # Delete the lsp from az1, the remote port in az2 should be gone -ovn-nbctl lsp-del lsp-ts1-lr1 +check ovn-nbctl lsp-del lsp-ts1-lr1 OVS_WAIT_WHILE([ovn_as az2 ovn-nbctl show | grep lsp-ts1-lr1]) OVN_CLEANUP_SBOX(gw1) @@ -1234,13 +1234,13 @@ ovn_as az1 check ovn-ic-nbctl --wait=sb sync lr=lr11 -ovn-nbctl lr-add $lr +check ovn-nbctl lr-add $lr lrp=lrp-$lr-ts1 lsp=lsp-ts1-$lr # Create LRP and connect to TS -ovn-nbctl lrp-add $lr $lrp aa:aa:aa:aa:a1:01 169.254.10.11/24 -ovn-nbctl lsp-add ts1 $lsp \ +check ovn-nbctl lrp-add $lr $lrp aa:aa:aa:aa:a1:01 169.254.10.11/24 +check ovn-nbctl lsp-add ts1 $lsp \ -- lsp-set-addresses $lsp router \ -- lsp-set-type $lsp router \ -- lsp-set-options $lsp router-port=$lrp @@ -2458,29 +2458,29 @@ ovn-ic-nbctl --wait=sb --may-exist ts-add tspeer # Create LRPs and connect to the peering TS ovn_as az1 -ovn-nbctl lrp-add lr11 lrp-lr11-tspeer aa:aa:aa:aa:11:01 169.254.103.11/24 -ovn-nbctl lsp-add tspeer lsp-tspeer-lr11 \ +check ovn-nbctl lrp-add lr11 lrp-lr11-tspeer aa:aa:aa:aa:11:01 169.254.103.11/24 +check ovn-nbctl lsp-add tspeer lsp-tspeer-lr11 \ -- lsp-set-addresses lsp-tspeer-lr11 router \ -- lsp-set-type lsp-tspeer-lr11 router \ -- lsp-set-options lsp-tspeer-lr11 router-port=lrp-lr11-tspeer ovn_as az2 -ovn-nbctl lrp-add lr12 lrp-lr12-tspeer aa:aa:aa:aa:12:01 169.254.103.12/24 -ovn-nbctl lsp-add tspeer lsp-tspeer-lr12 \ +check ovn-nbctl lrp-add lr12 lrp-lr12-tspeer aa:aa:aa:aa:12:01 169.254.103.12/24 +check ovn-nbctl lsp-add tspeer lsp-tspeer-lr12 \ -- lsp-set-addresses lsp-tspeer-lr12 router \ -- lsp-set-type lsp-tspeer-lr12 router \ -- lsp-set-options lsp-tspeer-lr12 router-port=lrp-lr12-tspeer ovn_as az1 -ovn-nbctl lrp-add lr21 lrp-lr21-tspeer aa:aa:aa:aa:21:01 169.254.103.21/24 -ovn-nbctl lsp-add tspeer lsp-tspeer-lr21 \ +check ovn-nbctl lrp-add lr21 lrp-lr21-tspeer aa:aa:aa:aa:21:01 169.254.103.21/24 +check ovn-nbctl lsp-add tspeer lsp-tspeer-lr21 \ -- lsp-set-addresses lsp-tspeer-lr21 router \ -- lsp-set-type lsp-tspeer-lr21 router \ -- lsp-set-options lsp-tspeer-lr21 router-port=lrp-lr21-tspeer ovn_as az2 -ovn-nbctl lrp-add lr22 lrp-lr22-tspeer aa:aa:aa:aa:22:01 169.254.103.22/24 -ovn-nbctl lsp-add tspeer lsp-tspeer-lr22 \ +check ovn-nbctl lrp-add lr22 lrp-lr22-tspeer aa:aa:aa:aa:22:01 169.254.103.22/24 +check ovn-nbctl lsp-add tspeer lsp-tspeer-lr22 \ -- lsp-set-addresses lsp-tspeer-lr22 router \ -- lsp-set-type lsp-tspeer-lr22 router \ -- lsp-set-options lsp-tspeer-lr22 router-port=lrp-lr22-tspeer