Re: [ovs-dev] [PATCH v2] netdev-offload: make netdev-offload-tc work with flow-restore-wait

2024-03-13 Thread Han Zhou
On Fri, Apr 22, 2022 at 1:41 AM Eelco Chaudron wrote: > > > > On 15 Apr 2022, at 13:25, wenx05124...@163.com wrote: > > > From: wenxu > > > > The netdev-offload in tc mode can't work with flow-restore-wait. > > When the vswitchd restart with flow-restore-wait, the tc qdisc > > will be delete in

Re: [ovs-dev] [PATCH] ofproto-dpif: Fix vxlan with different name del/add failed.

2024-03-13 Thread Han Zhou
Thanks Tao for fixing this. I think the title can be more generic because this problem and fix applies to all tunnel types rather than just VXLAN. On Tue, Mar 12, 2024 at 7:04 AM Tao Liu wrote: > > Reproduce: > ovs-vsctl add-port br-int p0 \ > -- set interface p0 type=vxlan

Re: [ovs-dev] [PATCH] ofproto-dpif-upcall: try lock for umap iteration during sweep

2024-03-13 Thread 0-day Robot
Bleep bloop. Greetings LIU Yulong, I am a robot and I have tried out your patch. Thanks for your contribution. I encountered some error that I wasn't expecting. See the details below. checkpatch: WARNING: The subject summary should start with a capital. WARNING: The subject summary should

[ovs-dev] [PATCH] ofproto-dpif-upcall: try lock for umap iteration during sweep

2024-03-13 Thread LIU Yulong
A potential race condition happened with the following 3 threads: * PMD thread replaced the old_ukey and transitioned the state to UKEY_DELETED. * RCU thread is freeing the old_ukey mutex. * While the revalidator thread is trying to lock the old_ukey mutex. Then vswitchd process aborts at the

[ovs-dev] [PATCH] ovs-monitor-ipsec: LibreSwan autodetect paths.

2024-03-13 Thread Mike Pattrick
In v4.0, LibreSwan changed a default paths that had been hardcoded in ovs-monitor-ipsec, breaking some uses of this script. This patch adds support for both old and newer versions by auto detecting the location of these paths from LibreSwan shell script environment variables. Reported-at:

Re: [ovs-dev] [PATCH OVN] ovn-nb: Add documentation for disable_arp_nd_rsp option

2024-03-13 Thread Numan Siddique
On Fri, Feb 16, 2024 at 10:54 PM Naveen Yerramneni wrote: > > Signed-off-by: Naveen Yerramneni Thanks. Applied to main. Numan > --- > ovn-nb.xml | 7 +++ > 1 file changed, 7 insertions(+) > > diff --git a/ovn-nb.xml b/ovn-nb.xml > index e0b983ed6..b652046a7 100644 > --- a/ovn-nb.xml >

[ovs-dev] [PATCH 3/3] netdev-dpdk: Fix tunnel type check during Tx offload preparation.

2024-03-13 Thread Ilya Maximets
Tunnel types are not flags, but 4-bit fields, so checking them with a simple binary 'and' is incorrect and may produce false-positive matches. While the current implementation is unlikely to cause any issues today, since both RTE_MBUF_F_TX_TUNNEL_VXLAN and RTE_MBUF_F_TX_TUNNEL_GENEVE only have 1

[ovs-dev] [PATCH 2/3] netdev-dpdk: Fix TCP check during Tx offload preparation.

2024-03-13 Thread Ilya Maximets
RTE_MBUF_F_TX_TCP_CKSUM is not a flag, but a 2-bit field, so checking it with a simple binary 'and' is incorrect. For example, this check will succeed for a packet with UDP checksum requested as well. Fix the check to avoid wrongly initializing tso_segz and potentially accessing UDP header via

[ovs-dev] [PATCH 0/3] netdev-dpdk: More Tx offlaod fixes.

2024-03-13 Thread Ilya Maximets
Stuff discovered while working on: https://github.com/openvswitch/ovs-issues/issues/321 Ilya Maximets (3): netdev-dpdk: Clear inner packet marks if no inner offloads requested. netdev-dpdk: Fix TCP check during Tx offload preparation. netdev-dpdk: Fix tunnel type check during Tx offload

[ovs-dev] [PATCH 1/3] netdev-dpdk: Clear inner packet marks if no inner offloads requested.

2024-03-13 Thread Ilya Maximets
In some cases only outer offloads may be requested for a tunneled packet. In this case there is no need to mark the type of an inner packet. Clean these flags up to avoid potential confusion of DPDK drivers. Fixes: 084c8087292c ("userspace: Support VXLAN and GENEVE TSO.") Signed-off-by: Ilya

[ovs-dev] [Patch ovn] docs: Remove ref. to "ovn-sbctl --no-wait".

2024-03-13 Thread Martin Kalcok
Couple places in the documentation reference "--wait" and "--no-wait" options for "ovn-sbctl" but it doesn't support these options [0]. Trying, for example, "ovn-sbctl --no-wait init" exits with: ovn-sbctl: --no-wait not supported [0]

Re: [ovs-dev] [PATCH] netdev-dpdk: Clean up all marker flags if no offloads requested.

2024-03-13 Thread Ilya Maximets
On 3/12/24 14:36, Mike Pattrick wrote: > On Mon, Mar 11, 2024 at 2:31 PM Ilya Maximets wrote: >> >> Some drivers (primarily, Intel ones) do not expect any marking flags >> being set if no offloads are requested. If these flags are present, >> driver will fail Tx preparation or behave abnormally.

[ovs-dev] [PATCH] conntrack: Fix SNAT with exhaustion system test.

2024-03-13 Thread Paolo Valerio
Recent kernels introduced a mechanism that allows to evict colliding entries in a closing state whereas they were previously considered as parts of a non-recoverable clash. This new behavior makes "conntrack - SNAT with port range with exhaustion test" fail, as it relies on the previous

Re: [ovs-dev] [PATCH v2 12/12] documentation: Document ovs-flowviz.

2024-03-13 Thread 0-day Robot
Bleep bloop. Greetings Adrian Moreno, I am a robot and I have tried out your patch. Thanks for your contribution. I encountered some error that I wasn't expecting. See the details below. checkpatch: WARNING: Line has trailing whitespace #206 FILE: Documentation/ref/ovs-flowviz.8.rst:126:

Re: [ovs-dev] [Patch ovn v2 1/2] actions: Enable specifying zone for ct_commit.

2024-03-13 Thread Martin Kalcok
On Tue, Mar 12, 2024 at 9:17 PM Martin Kalcok wrote: > Following up on the comments from v1. > > @amusil You were right that the struct in actions.h was not necessary > then. However I also noticed that I forgot to modify `format_CT_COMMIT_V1` > function and for that I think the struct is

Re: [ovs-dev] [Patch ovn v2 2/2] northd: Fix direct access to SNAT network on DR.

2024-03-13 Thread Martin Kalcok
Regarding the failed unstable test in the CI, I suspect that this is not related to the code change, I've had couple successful CI runs in my branch [0]. Martin. [0] https://github.com/mkalcok/ovn/actions/runs/8256539983 On Tue, Mar 12, 2024 at 8:45 PM Martin Kalcok wrote: > This change fixes

[ovs-dev] [PATCH v2 12/12] documentation: Document ovs-flowviz.

2024-03-13 Thread Adrian Moreno
Add a man page for ovs-flowviz as well as a topic page with some more detailed examples. Signed-off-by: Adrian Moreno --- Documentation/automake.mk | 4 +- Documentation/conf.py | 2 + Documentation/ref/index.rst | 1 +

[ovs-dev] [PATCH v2 11/12] python: ovs: flowviz: Support html dark style.

2024-03-13 Thread Adrian Moreno
In order to support dark style in html outputs, allow the config file to express the background color and set it in a top style object. Acked-by: Eelco Chaudron Signed-off-by: Adrian Moreno --- python/ovs/flowviz/html_format.py | 4 +++- python/ovs/flowviz/odp/html.py | 30

[ovs-dev] [PATCH v2 10/12] python: ovs: flowviz: Add datapath graph format.

2024-03-13 Thread Adrian Moreno
Graph view leverages the tree format (specially the tree-based filtering) and uses graphviz library to build a visual graph of the datapath in graphviz format. Conntrack zones are shown in random colors to help visualize connection tracking interdependencies. An html flag builds an HTML page

[ovs-dev] [PATCH v2 09/12] python: ovs: flowviz: Add datapath html format.

2024-03-13 Thread Adrian Moreno
Using the existing FlowTree and HTMLFormatter, create an HTML tree visualization that also supports collapsing and expanding entire flow trees and subtrees. Examples: $ ovs-appcl dpctl/dump-flows | ovs-flowviz --highlight drop datapath html > /tmp/flows.html $ ovs-appcl dpctl/dump-flows |

[ovs-dev] [PATCH v2 07/12] python: ovs: flowviz: Add OpenFlow logical view.

2024-03-13 Thread Adrian Moreno
This view is interesting for debugging the logical pipeline. It arranges the flows in "logical" groups (not to be confused with OVN's Logical_Flows). A logical group of flows is a set of flows that: - Have the same table number and priority - Match on the same fields (regardless of the value they

[ovs-dev] [PATCH v2 06/12] python: ovs: flowviz: Add datapath tree format.

2024-03-13 Thread Adrian Moreno
Datapath flows can be arranged into a "tree"-like structure based on recirculation ids, e.g: recirc(0),eth(...),ipv4(...) actions=ct,recirc(0x42) \-> recirc(42),ct_state(0/0),eth(...),ipv4(...) actions=1 \-> recirc(42),ct_state(1/0),eth(...),ipv4(...) actions=userspace(...) This patch

[ovs-dev] [PATCH v2 05/12] python: ovs: flowviz: Add html formatting.

2024-03-13 Thread Adrian Moreno
Add a HTML Formatter and use it to print OpenFlow flows in an HTML list with table links. Examples $ ovs-flowviz -i offlows.txt --highlight "drop" openflow html > /tmp/flows.html $ ovs-flowviz -i offlows.txt --filter "n_packets > 0" openflow html > /tmp/flows.html Acked-by: Eelco Chaudron

[ovs-dev] [PATCH v2 03/12] python: ovs: flowviz: Add console formatting.

2024-03-13 Thread Adrian Moreno
Add a flow formatting framework and one implementation for console printing using rich. The flow formatting framework is a simple set of classes that can be used to write different flow formatting implementations. It supports styles to be described by any class, highlighting and config-file based

[ovs-dev] [PATCH v2 08/12] python: ovs: flowviz: Add Openflow cookie format.

2024-03-13 Thread Adrian Moreno
When anaylizing OVN issues, it might be useful to see what OpenFlow flows were generated from each logical flow. In order to make it simpler to visualize this, add a cookie format that simply sorts the flows first by cookie, then by table. Example: $ export OVN_NB_DB=... $ export OVN_SB_DB=... $

[ovs-dev] [PATCH v2 02/12] python: ovs: flowviz: Add file processing infra.

2024-03-13 Thread Adrian Moreno
process.py contains a useful base class that processes files odp.py and ofp.py: contain datapath and openflow subcommand definitions as well as the first formatting option: json. Also, this patch adds basic filtering support. Examples: $ ovs-ofctl dump-flows br-int | ovs-flowviz openflow json $

[ovs-dev] [PATCH v1 00/12] Add flow visualization utility.

2024-03-13 Thread Adrian Moreno
The goal of this utility is to read both datapath and Openflow flows (using the flow library already available) and print them in different formats and styles to make it easier to understand them and troubleshoot issues. The formats are quite opinionated and so are the colors chosen so I'm eager

[ovs-dev] [PATCH v2 04/12] python: ovs: flowviz: Add default config file.

2024-03-13 Thread Adrian Moreno
It has two basic styles defined: "dark" and "light" intended for dark and light terminals. Examples: $ ovs-flowviz -i /tmp/dpflows --style=dark datapath console $ ovs-flowviz -i /tmp/ofpflows --style=light openflow console Acked-by: Eelco Chaudron Signed-off-by: Adrian Moreno ---

[ovs-dev] [PATCH v2 01/12] python: ovs: Add flowviz scheleton.

2024-03-13 Thread Adrian Moreno
Add a new python package (just the scheleton for now) to hold a flow visualization tool based on the flow parsing library. flowviz dependencies are installed via "extras_require", so a user must run: $ pip install .[flowviz] or $ pip install ovs[flowviz] Acked-by: Eelco Chaudron Signed-off-by:

Re: [ovs-dev] [RFC PATCH 0/4] net: openvswitch: Add sample multicasting.

2024-03-13 Thread Adrian Moreno
On 3/8/24 15:24, Ilya Maximets wrote: On 3/7/24 22:29, Ilya Maximets wrote: On 3/7/24 21:59, Adrian Moreno wrote: On 3/7/24 17:54, Ilya Maximets wrote: On 3/7/24 16:18, Adrian Moreno wrote: ** Background ** Currently, OVS supports several packet sampling mechanisms (sFlow, per-bridge