Hi Ben, In yesterday's meeting you asked about the different HA mechanisms supported by OVN.
Here's a brief summary. OVN supports 3 different ways to configure a distributed gateway router port. Out of which 2 supports HA with active/standby. The other is a legacy where we need to specify the chassis which handles gateway traffic. 1. Using legacy way of pinning the logical router port to a specific chassis. Eg. ovn-nbctl set logical_router_port lr0-public options:redirect-chassis=ch-1 2. Using Gateway_Chassis table in NB DB. Logical_Router_Port.gateway_chassis should be set for this. Here's an example on how CMS can use this method. ovn-nbctl lrp-set-gateway-chassis lr0-public ch-1 30 ovn-nbctl lrp-set-gateway-chassis lr0-public ch-2 20 ovn-nbctl lrp-set-gateway-chassis lr0-public ch-3 10 3. Using HA_Chassis_Group table in NB DB. Logical_Router_Port.ha_chassis_group should be set for this. Here's an example on how CMS can use this method. ovn-nbctl --wait=sb ha-chassis-group-add hagrp1 ovn-nbctl --wait=sb ha-chassis-group-add-chassis hagrp1 ch1 30 ovn-nbctl --wait=sb ha-chassis-group-add-chassis hagrp1 ch2 20 ovn-nbctl --wait=sb ha-chassis-group-add-chassis hagrp1 ch3 10 hagrp1_uuid=`ovn-nbctl --bare --columns _uuid find ha_chassis_group name=hagrp1` ovn-nbctl set logical_router_port lr0-public ha_chassis_group=$hagrp1_uuid ovn-northd only creates HA_Chassis_Group/HA_Chasss in SB DB only if the HA_Chassis_Group is associated to a logical router port. HA_Chassis_Group can also be associated to a logical switch port of type 'external'. HA Chassis with the higher priority will claim that port. ovn-northd gives precedence to (3) if it's configured ignoring other methods if configured. Then (2) and then (1). For all the 3 methods, ovn-northd creates HA_Chassis_Group/HA_Chassis rows in the South db and associates the HA_Chasssi_Group to PortBinding.ha_chassis_group. ovn-controller only looks into HA_Chassis_Group for claiming the distributed gateway ports and to establish BFD sessions. The Gateway_Chassis table in the SB DB is deprecated and not used anymore. >From what I know, OpenStack networking-ovn still makes use of approach (2). So we can't deprecate anytime soon. But I think we can definitely remove the support for (1). Removing (1) would result in some test case failures. Please let me know if you have any further questions. Thanks Numan _______________________________________________ discuss mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-discuss
