2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-28 21:07:47 +00:00

7 Commits

Author SHA1 Message Date
Adrián Moreno
340c574e46 utilities: upcall_monitor: Add extra info to pcap.
Use pcapng instead of pcap format and store the result, the key (if
available) and the input port name so they are visible in
wireshark/tshark.

Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
2025-04-09 10:47:47 +02:00
Adrián Moreno
c2deabc001 utilities: monitor_upcalls: Print ports from drops.
Drop events are generated from the kernel, not ovs-vswitchd so instead
of relying on nla decoding, copy the skb's device name directly into the
event.

Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
2025-04-09 10:47:47 +02:00
Adrián Moreno
acd6d21e32 utilities: upcall_monitor: Print port names.
Printing just the datapath on each upcall gives little information (most
often, there will only be one well-known datapath). Instead, print both
the input port name (plus the datapath).

In order to do this, refactor decode_nla to always generate the dump
that only gets printed if needed. That way it can be called earlier on.

Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
2025-04-09 10:47:47 +02:00
Adrián Moreno
ca804a7bef utilities: upcall_monitor: Allow filtering on result.
This patch makes it possible to display only succeeded or errored
upcalls.

Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
2025-04-09 10:47:43 +02:00
Adrián Moreno
c40a7ff9b0 utilities: upcall_monitor: Monitor dropped upcalls.
Generate events for dropped upcalls and add the print the result.

Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
2025-04-09 10:41:51 +02:00
Adrián Moreno
441407895d utilities: usdt-scripts: Remove sleep in loop.
Without this patch, the chances of events being lost on highly loaded
systems increase.

Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
2025-04-09 10:41:28 +02:00
Eelco Chaudron
51ec98635e utilities: Add upcall USDT probe and associated script.
Added the dpif_recv:recv_upcall USDT probe, which is used by the
included upcall_monitor.py script. This script receives all upcall
packets sent by the kernel to ovs-vswitchd. By default, it will
show all  upcall events, which looks something like this:

 TIME               CPU  COMM      PID      DPIF_NAME          TYPE PKT_LEN FLOW_KEY_LEN
 5952147.003848809  2    handler4  1381158  system@ovs-system  0    98      132
 5952147.003879643  2    handler4  1381158  system@ovs-system  0    70      160
 5952147.003914924  2    handler4  1381158  system@ovs-system  0    98      152

It can also dump the packet and NetLink content, and if required,
the packets can also be written to a pcap file.

Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
Acked-by: Paolo Valerio <pvalerio@redhat.com>
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
2022-01-18 00:46:30 +01:00