1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/network-observability-cli-capturing-packets.adoc
Sara Thomas 5dec11fe3c OSDOCS-11555:Configuring network observability network policy
OSDOCS-10036:Exporting Network Observability metrics to OpenTelemetry

OSDOCS-11731: Developer perspective for Network Observability

OSDOCS-10877: Virtualization in Network Observability

NetObserv FlowMetric API regeneration

Network Observability 1.7 regenerate flows format doc

OSDOCS-11821: NetObserv CLI updates

NetObserv 1.7 FlowCollector API regeneration

Network Observability 1.7 Release Notes
2024-10-22 15:53:54 +00:00

30 lines
1.2 KiB
Plaintext

//Module included in the following assemblies:
//
// observability/network_observability/netobserv_cli/netobserv-cli-using.adoc
:_mod-docs-content-type: PROCEDURE
[id="network-observability-cli-capturing-packets_{context}"]
= Capturing packets
You can capture packets using the Network Observability CLI.
.Prerequisites
* Install the {oc-first}.
* Install the Network Observability CLI (`oc netobserv`) plugin.
.Procedure
. Run the packet capture with filters enabled:
+
[source,terminal]
----
$ oc netobserv packets --action=Accept --cidr=0.0.0.0/0 --protocol=TCP --port=49051
----
. Add filters to the `live table filter` prompt in the terminal to refine the incoming packets. An example filter is as follows:
+
[source,terminal]
----
live table filter: [SrcK8S_Zone:us-west-1b] press enter to match multiple regular expressions at once
----
. Use the *PageUp* and *PageDown* keys to toggle between *None*, *Resource*, *Zone*, *Host*, *Owner* and *all of the above*.
. To stop capturing, press kbd:[Ctrl+C].
. View the captured data, which is written to a single file in an `./output/pcap` directory located in the same path that was used to install the CLI:
.. The `./output/pcap/<capture_date_time>.pcap` file can be opened with Wireshark.