No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Advanced O&M Command Reference

OceanStor 2800 V3 V300R006

This document is applicable to OceanStor 2800 V3. Based on the CLI, this document describes how to use various commands classified by functionsand how to set the CLI and manage the storage system through these commands. The document that you browse online matches the latest C version of the product. Click Download to download documents of other C versions.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
tcpdump.sh

tcpdump.sh

Function

The tcpdump.sh command is used to obtain network packet header information, excluding user sensitive data.

Format

tcpdump.sh [-i ?][-w ?][-c ?][src ?][and | or][dst ?][and | or][port ?][-k]|[-a]|[-h]

Parameters

Parameter

Description

Value

-i

Sets the listening network interface.

Network interface name.

-w

Sets a file to save the packets.

The value contains 1 to 80 ASCII characters including digits, letters, underscores (_), at sign (@), periods (.), and hyphens (-).

-c

Sets the number of network packets.

The value is an integer from 1 to 16000.

src

Sets the listening source address.

IP address.

dst

Sets the listening destination address.

IP address.

port

Sets the listening port.

Transport layer port number, ranging from 0 to 65535.

and

The filter conditions are "and" relationships that support SRC, DST, and port parameters.

-

or

The filter conditions are "or" relationships that support SRC, DST, and port parameters.

-

-k

Kills execution of background commands.

-

-h

Shows help information.

-

-a

Displays functions of each subcommand of the tcpdump module.

-

Modes

Minisystem mode

Usage Guidelines

None

Example

  • Obtain the network packet header information.
    Storage:minisystem>tcpdump.sh -i eth2 -c 5 src 8.46.7.157 and dst 8.46.23.146 -w test.cap 
    Command executes in the background, and the result will be saved to /OSM/coffer_log/log/tcpdump/test.cap. 
    tcpdump: listening on eth2, link-type EN10MB (Ethernet), capture size 64 bytes 
    Storage:minisystem>
  • Obtain the network packet header information, the result is syntax error.
    Storage:minisystem>tcpdump.sh -i eth2 -c 5 src 8.46.7.157 dst 8.46.23.146 
    tcpdump: syntax error 
    Storage:minisystem>

System Response

The following table describes the parameter meanings.

Parameter

Meaning

packets captured

Number of obtained packets.

packets received by filter

Number of filtered packets.

packets dropped by kernel

Number of dropped packets.

Translation
Download
Updated: 2019-07-12

Document ID: EDOC1000138381

Views: 667386

Downloads: 36

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next