Bug 2078552 - [ovn-northd] Add an explicit command line option to control lflow build parallelization.
Summary: [ovn-northd] Add an explicit command line option to control lflow build paral...
Keywords:
Status: POST
Alias: None
Product: Red Hat Enterprise Linux Fast Datapath
Classification: Red Hat
Component: OVN
Version: FDP 22.C
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: xsimonar
QA Contact: Ehsan Elahi
URL:
Whiteboard:
Depends On:
Blocks: 2067388
TreeView+ depends on / blocked
 
Reported: 2022-04-25 15:30 UTC by Dumitru Ceara
Modified: 2023-07-13 07:25 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed:
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker FD-1912 0 None None None 2022-04-25 15:50:09 UTC

Description Dumitru Ceara 2022-04-25 15:30:48 UTC
Description of problem:

It's currently possible to enable northd lflow build parallelization by
setting the NB.NB_Global.Options:use_parallel_build option to true in
the Northbound database.

If that gets toggled to "true" ovn-northd will by default determine the
number of CPUs and NUMAs available in the system and based on that
decide if it will actually enable parallelization and with how many
worker threads.

When running upstream self tests we sometimes "trick" ovn-northd into
believing that it runs on a single-NUMA node with 4 available CPUs:

https://github.com/ovn-org/ovn/blob/a0ded8874865d999ac9e8204c6affa4a5fd70699/tests/ovn-macros.at#L174

While the same approach might be used by a CMS to force ovn-northd to
use a given number of threads, it's probably better to have an explicit
command line argument to configure the number of threads ovn-northd
should use.

For example something like:

ovn-northd ... --n-threads=<VALUE> ..

To avoid confusion this should probably be made the only officially
supported way of enabling northd parallelization.  That means that:

- NB_Global.Options.use_parallel_build should become obsolete and be
  ignored by ovn-northd
- --dummy-numa should not have an effect on the number of worker
  threads ovn-northd spawns for lflow build parallelization

Additionally, it would be helpful if an appctl command would be added to
ovn-northd to allow users to dynamically change the number of threads
(and potentially disable) parallelization at runtime.  E.g.:

ovn-appctl -t ovn-northd parallel-build/n-threads <VALUE>

Comment 2 Dan Williams 2022-05-25 17:20:06 UTC
v5 was accepted upstream for 22.06 and later: http://patchwork.ozlabs.org/project/ovn/patch/20220519112017.1162522-1-xsimonar@redhat.com/


Note You need to log in before you can comment on or make changes to this bug.