From 731312df93534d9695b2d22fc9071a860868f87d Mon Sep 17 00:00:00 2001 From: Dave Barach Date: Mon, 23 Sep 2019 10:27:27 -0400 Subject: misc: unify pcap rx / tx / drop trace Use a single vnet_pcap_t in vlib_global_main, specifically to support unified tracing Update sphinx docs, doxygen tags Type: refactor Ticket: VPP-1776 Signed-off-by: Dave Barach Change-Id: Id15d41a596712968c0714cef1bd2cd5bc9cbdd55 (cherry picked from commit 33909777c63712ca397165cd92e7cc62208eb5c8) --- docs/gettingstarted/developers/vnet.md | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) (limited to 'docs') diff --git a/docs/gettingstarted/developers/vnet.md b/docs/gettingstarted/developers/vnet.md index b8f878c2cd7..826af0a90a9 100644 --- a/docs/gettingstarted/developers/vnet.md +++ b/docs/gettingstarted/developers/vnet.md @@ -470,25 +470,33 @@ This should be of significant value when developing new vpp graph nodes. If new code mispositions b->current_data, it will be completely obvious from looking at the dispatch trace in wireshark. -## pcap rx and tx tracing +## pcap rx, tx, and drop tracing -vpp also supports rx and tx packet capture in pcap format, through the -"pcap rx trace" and "pcap tx trace" debug CLI commands +vpp also supports rx, tx, and drop packet capture in pcap format, +through the "pcap trace" debug CLI command. -This command is used to start or stop a packet capture, or show -the status of packet capture. Note that both "pcap rx trace" and -"pcap tx trace" are implemented. The command syntax is identical, -simply substitute rx for tx as needed. +This command is used to start or stop a packet capture, or show the +status of packet capture. Each of "pcap trace rx", "pcap trace tx", +and "pcap trace drop" is implemented. Supply one or more of "rx", +"tx", and "drop" to enable multiple simultaneous capture types. These commands have the following optional parameters: -on|off- Used to start or stop a packet capture. +- rx - trace received packets. + +- tx - trace transmitted packets. + +- drop - trace dropped packets. - max _nnnn_ - file size, number of packet captures. Once packets have been received, the trace buffer buffer is flushed to the indicated file. Defaults to 1000. Can only be updated if packet capture is off. +- max-bytes-per-pkt _nnnn_ - maximum number of bytes to trace + on a per-paket basis. Must be >32 and less than 9000. Default value: + 512. + - intfc _interface_ | _any_ - Used to specify a given interface, or use 'any' to run packet capture on all interfaces. 'any' is the default if not provided. Settings from a previous -- cgit 1.2.3-korg