From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by passt.top (Postfix, from userid 1000) id 60FDE5A061A; Mon, 25 Nov 2024 11:58:01 +0100 (CET) From: Stefano Brivio To: passt-dev@passt.top Subject: [PATCH] test/perf: Select a single IPv6 namespace address in pasta tests Date: Mon, 25 Nov 2024 11:58:01 +0100 Message-ID: <20241125105801.266838-1-sbrivio@redhat.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-ID-Hash: ZL62LRYMW2NFGUNEIQI6KTZHDEUOVZQQ X-Message-ID-Hash: ZL62LRYMW2NFGUNEIQI6KTZHDEUOVZQQ X-MailFrom: sbrivio@passt.top X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: David Gibson X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: By dropping the filter on prefix length, commit 910f4f910301 ("test: Don't require 64-bit prefixes in perf tests") broke tests on setups where two global unicast IPv6 addresses are available, which is the typical case when the "host" is a VM running under passt with addresses from SLAAC and DHCPv6, because two addresses will be returned. Pick the first one instead. We don't really care about the prefix length, any of these addresses will work. Fixes: 910f4f910301 ("test: Don't require 64-bit prefixes in perf tests") Link: https://archives.passt.top/passt-dev/20241119214344.6b4a5b3a@elisabeth/ Signed-off-by: Stefano Brivio --- test/perf/pasta_tcp | 2 +- test/perf/pasta_udp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/perf/pasta_tcp b/test/perf/pasta_tcp index 88284b2..bc0de3c 100644 --- a/test/perf/pasta_tcp +++ b/test/perf/pasta_tcp @@ -211,7 +211,7 @@ tr TCP throughput over IPv6: host to ns iperf3s ns 10002 nsout IFNAME ip -j link show | jq -rM '.[] | select(.link_type == "ether").ifname' -nsout ADDR6 ip -j -6 addr show|jq -rM '.[] | select(.ifname == "__IFNAME__").addr_info[] | select(.scope == "global").local' +nsout ADDR6 ip -j -6 addr show|jq -rM '[.[] | select(.ifname == "__IFNAME__").addr_info[] | select(.scope == "global").local] | .[0]' bw - bw - bw - diff --git a/test/perf/pasta_udp b/test/perf/pasta_udp index 3d07091..ab2f3e8 100644 --- a/test/perf/pasta_udp +++ b/test/perf/pasta_udp @@ -196,7 +196,7 @@ tr UDP throughput over IPv6: host to ns iperf3s ns 10002 nsout IFNAME ip -j link show | jq -rM '.[] | select(.link_type == "ether").ifname' -nsout ADDR6 ip -j -6 addr show|jq -rM '.[] | select(.ifname == "__IFNAME__").addr_info[] | select(.scope == "global").local' +nsout ADDR6 ip -j -6 addr show|jq -rM '[.[] | select(.ifname == "__IFNAME__").addr_info[] | select(.scope == "global").local] | .[0]' iperf3 BW host __ADDR6__ 10002 __TIME__ __OPTS__ -b 8G -l 1472 bw __BW__ 0.3 0.5 iperf3 BW host __ADDR6__ 10002 __TIME__ __OPTS__ -b 12G -l 3972 -- 2.43.0