openvswitch / ovs-issues

Issue tracker repo for Open vSwitch
10 stars 3 forks source link

Why is per-vport dispatch mode being selected? #303

Closed seastco closed 1 year ago

seastco commented 1 year ago

I'm running OVS on an EC2 instance and trying to understand how/why dispatch mode is being selected as per-vport. I installed OVS via the ovs-node daemonset provided by ovn-kubernetes (image). On Azure I applied this same daemonset and see per-cpu mode. I suspect I'm seeing the thundering herd issue on EC2 and would like to use per-cpu mode as that's the setup I had working fine in Azure.

The kernel version of the EC2 instance is 5.10.186-179.751.amzn2.x86_64.

I'm not seeing the "Kernel does not correctly support feature negotiation. Using standard features." log, so I assume the fallback is happening here. But beyond that I'm getting lost.

openvswitchd logs:

Creating empty database /etc/openvswitch/conf.db.
Starting ovsdb-server.
Configuring Open vSwitch system IDs.
Enabling remote OVSDB managers.
Inserting openvswitch module.
Starting ovs-vswitchd.
Enabling remote OVSDB managers.
==> /var/log/openvswitch/ovs-vswitchd.log <==
2023-09-13T00:37:48.331Z|00001|vlog|INFO|opened log file /var/log/openvswitch/ovs-vswitchd.log
2023-09-13T00:37:48.364Z|00002|ovs_numa|INFO|Discovered 48 CPU cores on NUMA node 0
2023-09-13T00:37:48.364Z|00003|ovs_numa|INFO|Discovered 48 CPU cores on NUMA node 1
2023-09-13T00:37:48.364Z|00004|ovs_numa|INFO|Discovered 2 NUMA nodes and 96 CPU cores
2023-09-13T00:37:48.364Z|00005|reconnect|INFO|unix:/var/run/openvswitch/db.sock: connecting...
2023-09-13T00:37:48.364Z|00006|reconnect|INFO|unix:/var/run/openvswitch/db.sock: connected
2023-09-13T00:37:48.365Z|00007|dpdk|INFO|DPDK Disabled - Use other_config:dpdk-init to enable
2023-09-13T00:37:48.368Z|00008|bridge|INFO|ovs-vswitchd (Open vSwitch) 2.17.5
2023-09-13T00:38:47.969Z|00009|memory|INFO|35856 kB peak resident set size after 59.6 seconds
2023-09-13T00:38:47.969Z|00010|memory|INFO|idl-cells:17
2023-09-13T00:44:29.153Z|00011|dpif_netlink|INFO|Datapath dispatch mode: per-vport
...
igsilya commented 1 year ago

The kernel version of the EC2 instance is 5.10.186-179.751.amzn2.x86_64.

The per-cpu dispatch mode was introduced in upstream kernel 5.15.

seastco commented 1 year ago

That worked, thank you.