From patchwork Wed Nov 13 11:04:56 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Bianconi X-Patchwork-Id: 2010707 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=Kn+hNUfz; 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 4XpL6R6Jfvz1xty for ; Wed, 13 Nov 2024 22:05:18 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 1EA3340507; Wed, 13 Nov 2024 11:05:15 +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 KvAx3JdgxhVM; Wed, 13 Nov 2024 11:05:13 +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 8C3474038E Authentication-Results: smtp4.osuosl.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=Kn+hNUfz Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp4.osuosl.org (Postfix) with ESMTPS id 8C3474038E; Wed, 13 Nov 2024 11:05:13 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 677B0C08A9; Wed, 13 Nov 2024 11:05: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 487ACC08A8 for ; Wed, 13 Nov 2024 11:05:12 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 364FD812BC for ; Wed, 13 Nov 2024 11:05:12 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id YGjhfc4wbx6e for ; Wed, 13 Nov 2024 11:05:10 +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 smtp1.osuosl.org D80D781297 Authentication-Results: smtp1.osuosl.org; dmarc=pass (p=none dis=none) header.from=redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org D80D781297 Authentication-Results: smtp1.osuosl.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=Kn+hNUfz Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by smtp1.osuosl.org (Postfix) with ESMTPS id D80D781297 for ; Wed, 13 Nov 2024 11:05:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1731495907; 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; bh=szF7PaO5dDreno6DI4ZkG2fUQDKX33JzabtQJiNm/CM=; b=Kn+hNUfzF1a5rS0Qg/BmqK66G70Tm3vGp4yY99cmHltRDu4HdaAuF/8gWWBxpWEsvJobNp Pwn1qEoiOsaNWd3ypTQJ/v+Jh/s/mifFFZ5DzHu0KynoXdU/CcCfdTAthdwPY4VOlSlJzr zy+2MDPdhkiQPke+olovmOmenIqFqd0= Received: from mail-wm1-f72.google.com (mail-wm1-f72.google.com [209.85.128.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-30-XM7Gb3pQM9WHpNht7BlfWA-1; Wed, 13 Nov 2024 06:05:06 -0500 X-MC-Unique: XM7Gb3pQM9WHpNht7BlfWA-1 X-Mimecast-MFC-AGG-ID: XM7Gb3pQM9WHpNht7BlfWA Received: by mail-wm1-f72.google.com with SMTP id 5b1f17b1804b1-432d8843783so464055e9.3 for ; Wed, 13 Nov 2024 03:05:06 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1731495905; x=1732100705; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=szF7PaO5dDreno6DI4ZkG2fUQDKX33JzabtQJiNm/CM=; b=HkjghGsrmytZ65SEDJIDFIOPoEwbvj4QjPo29WHzTOxTR4WLzDOjlAX+3ePy8u+8cg MdFe1D4sZ11fo8SoQp07GwljW8igoq64kFDCyrEJf10mQswd8A2Lg+/lm7pTQLa81c6R KO8+/9A1T/TZRZQ0uDh0CWbRM91rkPhSJtSEbhqyeOnwo8rSbwBeE2o0hY5kFlaIRAbk ed73sAwt6IlB0qjQY3i89vALRSxUXPZLHYG+NFTjBjzBl45gSeW5zqSN0B2YJcSWtson I1BA7YL/HYO8LS4sgBL/1NoGGQ5r8f5vxXRrnNR0D1MZI8Zf9NywQxwuNubdfroA+nv9 lJgg== X-Gm-Message-State: AOJu0YzoF0/S4TrQ0P/PwGR01vfzkXeX8EKUeqwsdQaP+7DgTd6zUR8Q i69vdG3bmRDgCU+tUj0AUtsuw12HhNM1kZAQyJT/eH4uil5rHAD7CeR5WWckhmuhOFViz7yJK9Q 1TjiQaZItwSu3mTtsY2q4LWtnDwTJmQtdKpdlvQRoL/u0oqa9nEjy+sglKeiRa56jbgwHjasqwk w8+zMK33WYQ/4B+mAQ5MrspESR0n0w2O4dZH1TS59ADH+zeQwyBg== X-Received: by 2002:a05:600c:3ca8:b0:42c:c003:edd1 with SMTP id 5b1f17b1804b1-432b7501d59mr176774055e9.10.1731495905319; Wed, 13 Nov 2024 03:05:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IHI5l71pCIW6Pr4M7jalDd5F3r0PnD9YR/I49kGa0rp569pFCD/fBZFD4CGP8aeOsqiMwF8OA== X-Received: by 2002:a05:600c:3ca8:b0:42c:c003:edd1 with SMTP id 5b1f17b1804b1-432b7501d59mr176773795e9.10.1731495904892; Wed, 13 Nov 2024 03:05:04 -0800 (PST) Received: from localhost (net-93-146-37-148.cust.vodafonedsl.it. [93.146.37.148]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-432d54e0e4csm20541145e9.6.2024.11.13.03.05.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Nov 2024 03:05:04 -0800 (PST) From: Lorenzo Bianconi To: ovs-dev@openvswitch.org Date: Wed, 13 Nov 2024 12:04:56 +0100 Message-ID: X-Mailer: git-send-email 2.47.0 MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: HUwbNVGz1ZPFaDXgdMc7L2qRPyQXUHfOFliHcVe-QE0_1731495906 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH ovn 0/4] Introduce ECMP_nexthop monitor in ovn-controller 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: , Cc: dceara@redhat.com Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" With respect to the previous implementation, OVN is now tracking and flushing ECMP next-hop ct entries with the next-hop mac address instead of using an identification number committed by ovn-northd since the previous approach had some limitations when the traffic is initialized from outside the ovn cluster. This series is introducing a way to periodically resolve L2 address of the configured next-hops. Please note IPv6 is not currently supported and it will be added before posting a formal series. The goal of this series is just to collect feedbacks about the proposed approach. Changes in v1: - Flush just ecmp ct entries in the router ct zone Changes in RFC v3: - move ecmp-next-hop-monitor code in controller/ecmp-next-hop-monitor.{c,h} - use a hamp for send_arp_nd_data since the same nexthop can be used by multiple ports/routes - add new system-ovn test to check when a given next-hop is used by multiple ovn-routers/ecmp routes - use a Port_Binding reference in ECMP_Nexthop - use nexthop and port as ECMP_Nexthop table index - move ECMP_Nexthop mac binding update in mac_binding_add_to_sb() - cosmetics Changes in RFC v2: - add IPv6 support Lorenzo Bianconi (4): northd: Introduce ECMP_Nexthop table in SB db. pinctrl: Send periodic arp/nd to ecmp next-hops. pinctrl: Update ecmp-nexthop mac resolving L2 address. ofctrl: Introduce ecmp_nexthop_monitor. NEWS | 7 + controller/automake.mk | 4 +- controller/ecmp-next-hop-monitor.c | 184 ++++++++++ controller/ecmp-next-hop-monitor.h | 25 ++ controller/ofctrl.c | 7 + controller/ofctrl.h | 3 + controller/ovn-controller.8.xml | 10 + controller/ovn-controller.c | 10 + controller/pinctrl.c | 368 +++++++++++++++++++- controller/pinctrl.h | 3 + include/ovn/logical-fields.h | 3 + northd/en-northd.c | 29 ++ northd/en-northd.h | 4 + northd/inc-proc-northd.c | 9 +- northd/northd.c | 104 +++++- northd/northd.h | 6 + ovn-sb.ovsschema | 17 +- ovn-sb.xml | 31 ++ tests/ovn-northd.at | 33 +- tests/system-ovn.at | 526 +++++++++++++++++++++++++++++ 20 files changed, 1355 insertions(+), 28 deletions(-) create mode 100644 controller/ecmp-next-hop-monitor.c create mode 100644 controller/ecmp-next-hop-monitor.h