From patchwork Mon Jan 22 17:23:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ilya Maximets X-Patchwork-Id: 1889288 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.133; helo=smtp2.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=patchwork.ozlabs.org) Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (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 4TJcW95dPGz1yS7 for ; Tue, 23 Jan 2024 04:23:17 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id D3284419CE; Mon, 22 Jan 2024 17:23:15 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org D3284419CE X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id N1qkxQ1LAfnw; Mon, 22 Jan 2024 17:23:15 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp2.osuosl.org (Postfix) with ESMTPS id 06529419B4; Mon, 22 Jan 2024 17:23:13 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 06529419B4 Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id D1B87C0072; Mon, 22 Jan 2024 17:23:13 +0000 (UTC) X-Original-To: ovs-dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by lists.linuxfoundation.org (Postfix) with ESMTP id 0121EC0037 for ; Mon, 22 Jan 2024 17:23:12 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id D169981424 for ; Mon, 22 Jan 2024 17:23:11 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org D169981424 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id rDwpIU8WNwNE for ; Mon, 22 Jan 2024 17:23:11 +0000 (UTC) Received: from relay2-d.mail.gandi.net (relay2-d.mail.gandi.net [217.70.183.194]) by smtp1.osuosl.org (Postfix) with ESMTPS id E394D813DE for ; Mon, 22 Jan 2024 17:23:10 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org E394D813DE Received: by mail.gandi.net (Postfix) with ESMTPSA id E07B940002; Mon, 22 Jan 2024 17:23:07 +0000 (UTC) From: Ilya Maximets To: ovs-dev@openvswitch.org Date: Mon, 22 Jan 2024 18:23:06 +0100 Message-ID: <20240122172307.3801928-1-i.maximets@ovn.org> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-GND-Sasl: i.maximets@ovn.org Cc: Ilya Maximets Subject: [ovs-dev] [PATCH] ci: Run system tests in a separate namespace. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" GitHub runners use 10.1.0.0/16 network as their base network for eth0 interface. That is causing random system test failures when unexpected conntrack entries for this network are present, because our system tests are mainly using 10.1.1.0/24 subnet for their test networks. Run system tests in their own network namespace to avoid any unwanted interference. Ideally, we would run every single test in its own namespace, but that is not a trivial change and will likely be hard to backport. Still worth investigating in the future. Note: Layer3 tunnel tests with Bareudp ports rely on loopback to work, but lo interface is down by default in new namespaces. So, bringing it up. These tests are skipped in Ubuntu 22.04, because it doesn't have bareudp support, but it's better to have the change anyway, so it doesn't bite us in the future while upgrading the base image. Signed-off-by: Ilya Maximets Acked-by: Eelco Chaudron Acked-by: Simon Horman --- .ci/linux-build.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.ci/linux-build.sh b/.ci/linux-build.sh index 7c2aebad8..bf9d6241d 100755 --- a/.ci/linux-build.sh +++ b/.ci/linux-build.sh @@ -157,6 +157,10 @@ else if [ "$testsuite" != "check" ] && \ [ "$testsuite" != "check-ovsdb-cluster" ] ; then run_as_root="sudo -E PATH=$PATH GITHUB_ACTIONS=$GITHUB_ACTIONS" + sudo ip netns add ovs-system-test-ns + # Some system tests may rely on traffic loopback. + sudo ip -netns ovs-system-test-ns link set dev lo up + run_as_root="${run_as_root} ip netns exec ovs-system-test-ns" fi if [ "${testsuite##*dpdk}" != "$testsuite" ]; then sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' || true