Add MAC binding aging mechanism, that should take care of stale MAC bindings.
The mechanism is configurable per logical router, with option called "mac_binding_age_threshold", which is 0 by default. The zero also indicates that the aging mechanism is disabled. The aging is based on timestamp in MAC_binding table, rows that exceed threshold specified by the LR option will be deleted. The row timestamp is refresh when we receive ARP that changes MAC address of corresponding row. In order to prevent big pressure on SB DB limit how many MAC bindings can be removed at once. The limit is currently set to 15 rows with delay of 10 msec before next batch. The test case is present as separate patch of the series. Ales Musil (6): northd, controller: Add timestamp column to MAC_Binding table controller: Add mac-binding-index.c/.h files northd: Move struct ovn_datapath and related structs to northd.h northd: Add MAC binding aging mechanism ovn.at: Add test case covering the MAC binding aging northd: Limit bulk removal of MAC binding aging controller/ovn-controller.c | 8 +- controller/pinctrl.c | 2 + lib/automake.mk | 2 + lib/mac-binding-index.c | 35 ++++++++ lib/mac-binding-index.h | 26 ++++++ northd/automake.mk | 2 + northd/inc-proc-northd.c | 13 +++ northd/mac-binding-aging.c | 166 ++++++++++++++++++++++++++++++++++++ northd/mac-binding-aging.h | 33 +++++++ northd/northd.c | 154 --------------------------------- northd/northd.h | 158 ++++++++++++++++++++++++++++++++++ northd/ovn-northd.c | 2 +- ovn-nb.xml | 7 ++ ovn-sb.ovsschema | 5 +- ovn-sb.xml | 6 ++ tests/ovn.at | 109 +++++++++++++++++++++++ 16 files changed, 566 insertions(+), 162 deletions(-) create mode 100644 lib/mac-binding-index.c create mode 100644 lib/mac-binding-index.h create mode 100644 northd/mac-binding-aging.c create mode 100644 northd/mac-binding-aging.h -- 2.35.3 _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
