neutron/neutron/tests/unit/plugins/ml2
Daniel Alvarez Sanchez b767825d13 [ovn] Stop monitoring the SB MAC_Binding table to reduce mem footprint
The MAC_Binding table in the SB database may grow indefinitely (due
to a lack of an aging mechanism of its entries) and eventually
lead to OOM killers for neutron-server which maintains an in-memory
copy of the database.

In order to stop monitoring this table, this patch is invoking
the ovsdb-client tool to remove the entries associated to
Floating IPs that have just been detached. The execution of this
tool is really fast as it will just invoke a JSON-RPC transact command
which doesn't require downloading the database contents.

In a scale test, the memory consumption of neutron-server dropped
from 75GB to 7GB with this patch.

Closes-Bug: #1946318

Conflicts:
  neutron/plugins/ml2/drivers/ovn/mech_driver/mech_driver.py
  neutron/tests/functional/plugins/ml2/drivers/ovn/mech_driver/ovsdb/test_ovsdb_monitor.py
  neutron/tests/unit/plugins/ml2/drivers/ovn/mech_driver/test_mech_driver.py

Note: The functional test has been changed for this stable branch
because the update_tables() method from ovsdbapp is not availabie for
this version of Neutron. So I changed the functional test to add the
MAC_Binding entry via ovsdb-client instead of using ovsdbapp to do so.

Signed-off-by: Daniel Alvarez Sanchez <dalvarez@redhat.com>
Change-Id: Id84bf17953527c415d611bfc198038fb6f811de3
(cherry picked from commit f6c3552769)
2021-10-26 13:32:15 +01:00
..
drivers [ovn] Stop monitoring the SB MAC_Binding table to reduce mem footprint 2021-10-26 13:32:15 +01:00
extensions Fix bulk port tag test_type_args_passed_to_extension() 2020-03-06 09:21:03 -05:00
__init__.py Reorganize unit test tree 2015-04-06 23:28:31 +00:00
_test_mech_agent.py Check mech driver connectivity during port binding 2019-09-11 07:05:54 +00:00
base.py use service type constants from neutron_lib plugins 2017-06-27 15:16:05 -06:00
test_agent_scheduler.py Start enforcing E125 flake8 directive 2019-07-19 23:39:41 -04:00
test_db.py Auto-delete dhcp ports on segment delete 2020-07-13 12:40:18 +02:00
test_driver_context.py Use objects instead of SQLA deep copies in PortContext 2017-06-20 01:34:10 -07:00
test_ext_portsecurity.py PSExtDriverTestCase: initialize variable in case of exception 2019-10-30 17:44:45 -04:00
test_extension_driver_api.py Use constant IP_VERSION_4/6 in unit tests 2018-08-27 21:45:39 +00:00
test_managers.py Add "project_id" filter when changing the network segmentation ID 2020-02-17 16:03:17 +00:00
test_ovo_rpc.py Stop loading OVOServerRpcInterface in ML2 testcase 2017-04-18 01:27:37 -07:00
test_plugin.py Lock subnets during port creation and subnet deletion 2020-04-23 16:43:19 +00:00
test_port_binding.py Drive binding by placement allocation 2019-03-09 22:03:51 +00:00
test_rpc.py ovs agent: signal to plugin if tunnel refresh needed 2020-01-09 14:18:43 +00:00
test_security_group.py Start enforcing E125 flake8 directive 2019-07-19 23:39:41 -04:00
test_tracked_resources.py Support for stateless security groups 2020-03-03 16:53:42 +01:00