From patchwork Thu Mar 14 19:30:56 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Numan Siddique X-Patchwork-Id: 1056667 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=openvswitch.org (client-ip=140.211.169.12; helo=mail.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=redhat.com Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 44KzN61qPsz9ryj for ; Fri, 15 Mar 2019 06:31:16 +1100 (AEDT) Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 17770CC1; Thu, 14 Mar 2019 19:31:13 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id 8296DCB7 for ; Thu, 14 Mar 2019 19:31:11 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 4E8D3D3 for ; Thu, 14 Mar 2019 19:31:10 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B315C30FE5A1 for ; Thu, 14 Mar 2019 19:31:09 +0000 (UTC) Received: from nusiddiq.mac (unknown [10.67.116.14]) by smtp.corp.redhat.com (Postfix) with ESMTP id 92DAB6B8FE; Thu, 14 Mar 2019 19:31:08 +0000 (UTC) From: nusiddiq@redhat.com To: dev@openvswitch.org Date: Fri, 15 Mar 2019 01:00:56 +0530 Message-Id: <20190314193056.24241-1-nusiddiq@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.47]); Thu, 14 Mar 2019 19:31:09 +0000 (UTC) X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Subject: [ovs-dev] [PATCH v4 0/5] ovn: Add HA chassis group and 'external' port X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: ovs-dev-bounces@openvswitch.org Errors-To: ovs-dev-bounces@openvswitch.org From: Numan Siddique This patch series adds a generic HA chassis group support in OVN deprecating the existing Gateway chassis support. The final patch of the series adds the 'external' port support in OVN. The 'external' port patch addresses the review comments from Han Zhou which he provided when 'external' port patch was submitted without the HA support. A generic HA chassis group support is added so that both the distributed logical router ports (providing gateway functionality) and 'external' ports can use it for HA and also to simplify the existing HA code (which seems to be a bit complicated). To support HA, BFD is configured on tunnel ports. And even though 'external' ports are expected to be used with the logical switches having localnet ports (representing physical networks), BFD is used for now since each chassis uses geneve tunnels with all other chassis in the OVN cluster. v3 -> v4 ----- * Addressed the review comments from Han on patch 2. v2 -> v3 ------ * Addressed the review comments from Han on patch 2. - Added the code to set the ref_chassis for cases where a logical port can reach a gateway router port via indirect connections. - Removed the deprecation message about Gateway_chassis in ovn-nb.xml * Rebased few patches to resolve merge conflicts. v1 -> v2 ------- * Rebased as there were merge conflicts * Addressed the review comment from Han in the patch 1. Numan Siddique (5): ovn-northd: Reuse the hmaps - datapaths and ports in ovnsb_db_run() ovn: Add generic HA chassis group ovn-controller: Make use of ha_chassis_group table to bind the chassisredirect ports ovn-northd: Delete the references to gateway_chasss in SB DB ovn: Support a new Logical_Switch_Port.type - 'external' NEWS | 2 + ovn/controller/automake.mk | 4 +- ovn/controller/bfd.c | 229 +++---- ovn/controller/bfd.h | 11 +- ovn/controller/binding.c | 31 +- ovn/controller/binding.h | 1 - ovn/controller/gchassis.c | 222 ------- ovn/controller/gchassis.h | 71 --- ovn/controller/ha-chassis.c | 203 ++++++ ovn/controller/ha-chassis.h | 50 ++ ovn/controller/lflow.c | 29 +- ovn/controller/lflow.h | 3 +- ovn/controller/ovn-controller.c | 14 +- ovn/controller/physical.c | 109 ++-- ovn/controller/physical.h | 3 +- ovn/controller/pinctrl.c | 38 +- ovn/controller/pinctrl.h | 1 - ovn/lib/chassis-index.c | 26 + ovn/lib/chassis-index.h | 4 + ovn/lib/ovn-util.c | 1 + ovn/northd/ovn-northd.8.xml | 37 +- ovn/northd/ovn-northd.c | 934 ++++++++++++++++++++------- ovn/ovn-architecture.7.xml | 71 +++ ovn/ovn-nb.ovsschema | 42 +- ovn/ovn-nb.xml | 131 ++++ ovn/ovn-sb.ovsschema | 43 +- ovn/ovn-sb.xml | 63 ++ ovn/utilities/ovn-nbctl.8.xml | 41 ++ ovn/utilities/ovn-nbctl.c | 221 +++++++ ovn/utilities/ovn-sbctl.c | 6 + tests/ovn-northd.at | 567 ++++++++++++++++- tests/ovn.at | 1041 ++++++++++++++++++++++++++++++- 32 files changed, 3390 insertions(+), 859 deletions(-) delete mode 100644 ovn/controller/gchassis.c delete mode 100644 ovn/controller/gchassis.h create mode 100644 ovn/controller/ha-chassis.c create mode 100644 ovn/controller/ha-chassis.h