DUMPCAP(1)
π DUMPCAP(1) π β the dumpcap manual, bestie edition
okay so real talk: dumpcap is that girl. she's a network traffic dump tool and she's about to make packet capture make sense, fr fr. let's go π
β¨ NAME β¨
dumpcap β dump network traffic π
π¦ SYNOPSIS π¦
dumpcap [ -a|--autostop <capture autostop condition> ] ...
[ -b|--ring-buffer <capture ring buffer option> ] ...
[ -B|--buffer-size <capture buffer size> ] [ -c <capture packet count> ]
[ -C <byte limit> ] [ -d ] [ -D|--list-interfaces ]
[ -f <capture filter> ] [ -F <file format> ] [ -g ]
[ -i|--interface <capture interface>|rpcap://<host>:<port>/<capture interface>|- ]
[ -I|--monitor-mode ]
[ -k <freq>,[<type>],[<center_freq1>],[<center_freq2>] ]
[ -L|--list-data-link-types ] [ -M ] [ -n ] [ -N <packet limit> ]
[ -p|--no-promiscuous-mode ] [ --ifdescr <description> ]
[ --ifname <name> ] [ -P ] [ -q ] [ -Q ]
[ -s|--snapshot-length <capture snaplen> ] [ -S ] [ -t ]
[ --temp-dir <directory> ] [ -w <outfile> ]
[ -y|--linktype <capture link type> ]
[ --application-flavor [wireshark|stratoshark] ]
[ --capture-comment <comment> ] [ --list-time-stamp-types ]
[ --no-optimize ] [ --process-info[=basic|full] ]
[ --time-stamp-type <type> ] [ --update-interval <interval> ]
dumpcap -h|--help
dumpcap -v|--version
πΈ DESCRIPTION πΈ
So dumpcap is a network traffic dump tool, periodt. She lets you capture packet data from a live network and write those packets straight into a file. Her default capture file format is pcapng format β but if you want the classic pcap vibe, you can pass the -F option and she'll write the output file in the pcap format instead. π«
Now, if you run her with literally no options set, she'll use the libpcap or Npcap library to capture traffic from the first available network interface, and she writes the received raw packet data β plus the packets' time stamps β into a capture file. iconic behaviour honestly.
If you don't specify the -w option, dumpcap writes to a newly created capture file with a randomly chosen name. If you do specify -w, she writes to the file you named in that option. simple as that π
Packet capturing is performed with the pcap library, and the capture filter syntax follows the rules of the pcap library. iykyk.
β¨ OPTIONS β¨
-a,--autostop<capture autostop condition> β telldumpcapwhen to stop writing to a capture file. the criterion is of the formtest:value, wheretestis one of the following:duration:valueβ stop writing to a capture file aftervalueseconds have elapsed. floating point values (e.g.0.5) are allowed. β³files:valueβ stop writing to capture files aftervaluenumber of files were written.filesize:valueβ stop writing to a capture file after it reaches a size ofvaluekB. if this option is used together with the-boption,dumpcapwill stop writing to the current capture file and switch to the next one iffilesizeis reached. note that thefilesizeis limited to a maximum value of 2 TB. π«packets:valueβ stop writing to a capture file aftervaluepackets have been written. acts the same as-c <capture packet count>.
-b,--ring-buffer<capture ring buffer option> β this makesdumpcaprun in "multiple files" mode. in "multiple files" mode, she writes to several capture files. when the first capture file fills up,dumpcapswitches writing to the next file and so on. π
the created filenames are based on the filename you gave with the -w option, the number of the file, and the creation date and time, like:
outfile_00001_20260714120117.pcapng
outfile_00002_20260714120523.pcapng
...
with the files option it's also possible to form a "ring buffer". this fills up new files until the number of files you specified, at which point dumpcap discards the data in the first file and starts writing to that file again, and so on. if the files option is not set, new files fill up until one of the capture stop conditions match (or until the disk is full π).
the criterion is of the form key:value, where key is one of:
duration:valueβ switch to the next file aftervalueseconds have elapsed, even if the current file isn't completely filled up. floating point values (e.g.0.5) are allowed.files:valueβ begin again with the first file aftervaluenumber of files were written (form a ring buffer). this value must be less than100000. caution should be used when using large numbers of files: some filesystems do not handle many files in a single directory well. thefilescriterion requires eitherduration,intervalorfilesizeto be specified to control when to go to the next file. also, heads up: each-bparameter takes exactly one criterion β to specify two criteria, each must be preceded by the-boption. πfilesize:valueβ switch to the next file after it reaches a size ofvaluekB. note that thefilesizeis limited to a maximum value of 2 TB.interval:valueβ switch to the next file when the time is an exact multiple ofvalueseconds. for example, use3600to switch to a new file every hour on the hour. β°packets:valueβ switch to the next file after it containsvaluepackets.printname:filenameβ print the name of the most recently written file tofilenameafter the file is closed.filenamecan bestdoutor-for standard output, orstderrfor standard error.
Example: -b filesize:1000 -b files:5 results in a ring buffer of five files of size one megabyte each. π
-B,--buffer-size<capture buffer size> β set the capture buffer size in MiB. the default is 2 MiB. the capture driver uses this to buffer packet data until that data can be written to disk. if you're seeing packet drops while capturing, try bumping this size up. but ngl, note this: whiledumpcapattempts to set the buffer size to2 MiBby default (and can be told to set it to a larger value), the system or interface you're capturing on might silently limit the capture buffer size to a lower value, or raise it to a higher value. sneaky.
this is available on UNIX-compatible systems β such as Linux, macOS, \*BSD, Solaris, and AIX β with libpcap 1.0.0 or later, and on Windows. it is not available on UNIX-compatible systems with earlier versions of libpcap. π
this option can occur multiple times. if used before the first occurrence of the -i option, it sets the default capture buffer size. if used after an -i option, it sets the capture buffer size for the interface specified by the last -i option occurring before this option. if the capture buffer size is not set specifically, the default capture buffer size is used instead.
-c<capture packet count> β set the maximum number of packets to read when capturing live data. acts the same as-a packets:<capture packet count>.-C<byte limit> β limit the amount of memory in bytes used for storing captured packets in memory while processing it. if used in combination with the-Noption, both limits will apply. setting this limit will enable the usage of the separate thread per interface. π§΅-dβ dump the code generated for the capture filter(s) in a human-readable form, and exit. if capturing on multiple interfaces, the capture filter for each interface will be printed in the order that the interfaces were specified. (note that a capture filter may compile differently on different interfaces.) π-D,--list-interfacesβ print a list of the interfaces on whichdumpcapcan capture, and exit. for each network interface, a number and an interface name is printed β possibly followed by a text description of the interface. the interface name or the number can be supplied to the-iflag to specify an interface on which to capture. the number can be useful on Windows systems, where the interfaces have long names that usually contain a GUID. πͺ-f<capture filter> β set the capture filter expression. π―
the entire filter expression must be specified as a single argument (which means that if it contains spaces, it must be quoted).
this option can occur multiple times. if used before the first occurrence of the -i option, it sets the default capture filter expression. if used after an -i option, it sets the capture filter expression for the interface specified by the last -i option occurring before this option. if the capture filter expression is not set specifically, the default capture filter expression is used if provided.
-F<file format> β set the file format of the output capture file written using the-woption. in situations that require the pcapng format β such as capturing from multiple interfaces β this option will be overridden. the option-Fwithout a value will list the available formats. the default is the pcapng format. π
fewer formats are supported than bytshark(1); this is intentional for security reasons. usetsharkor capture and then convert the file witheditcap(1)if another format is needed. π
-gβ this option causes the output file(s) to be created with group-read permission (meaning that the output file(s) can be read by other members of the calling user's group). π«Ά-h,--helpβ print the version number and options and exit.-i,--interface<capture interface>|rpcap://<host>:<port>/<capture interface>|-β set the name of the network interface or pipe to use for live packet capture. π¦
network interface names should match one of the names listed in "tshark -D" (described above); a number, as reported by "dumpcap -D", can also be used.
if no interface is specified, dumpcap searches the list of interfaces, choosing the first non-loopback interface if there are any non-loopback interfaces, and choosing the first loopback interface if there are no non-loopback interfaces. if there are no interfaces at all, dumpcap reports an error and doesn't start the capture. π€
pipe names should either be the name of a FIFO (named pipe) or - to read data from the standard input. on Windows systems, pipe names must be of the form "\\.\pipe\pipename". data read from pipes must be in standard pcapng or pcap format, and pcapng data must have the same endianness as the capturing host. πͺ
this option can occur multiple times. when capturing from multiple interfaces, the capture file will be saved in pcapng format, even if -P is specified.
--ifdescr<description> β usedescriptionas the description in the capture file for the interface or pipe specified before it with-i. βοΈ--ifname<name> β usenameas the name in the capture file for the interface or pipe specified before it with-i.-I,--monitor-mode
...okay so let's keep going with the options, because we're literally not even close to done π
Put the interface in "monitor mode"; this is supported only on IEEE 802.11 Wi-Fi interfaces, and supported only on some operating systems.
Bestie, listen to me: in monitor mode the adapter might disassociate from the network it's currently associated with, so you won't be able to use any wireless networks with that adapter. That could block you from grabbing files off a network server, or resolving host names or network addresses β yep, even if you're capturing in monitor mode and aren't connected to some other network with another adapter. π
This option can occur multiple times, lowkey. If you use it before the first occurrence of the -i option, it enables monitor mode for all interfaces. If you use it after an -i option, it enables monitor mode for the interface specified by the last -i option that occurred before this one. Slay, that's the whole pattern, you'll see it everywhere.
-k <freq>,[<type>],[<center_freq1>],[<center_freq2>]β set the channel on the interface β¨ this is supported only on IEEE 802.11 Wi-Fi interfaces, and supported only on some operating systems, ngl.
So freq is the frequency of the channel. type is the type of the channel for 802.11n and later. The values for type are:
NOHTβ used for 802.11b/g channelsHT20β 20 MHz channelHT40-β 40 MHz primary channel and a lower secondary channelHT40+β 40 MHz primary channel and a higher secondary channelHE40β 40 MHz channel, withcenterfreq1as its center frequencyHT80β 80 MHz channel, withcenterfreq1as its center frequencyVHT80+80β two 80 MHz channels combined, withcenterfreq1andcenterfreq2as the center frequencies of the two channelsVHT160β 160 MHz channel, withcenterfreq1as its center frequencyEHT320β 320 MHz channel, withcenterfreq1as its center frequency
-L,--list-data-link-typesβ list the data link types supported by the interface and then exit. The reported link types are the exact values you can feed to the-yoption. Iconic. π-Mβ when it's used with-D,-L,-Sor--list-time-stamp-types, print machine-readable output. This machine-readable output is meant to be read by Wireshark and TShark, and heads up: its format is subject to change from release to release. So don't go building your whole personality on it, k? π-nβ save files as pcapng. This is the default. This option is deprecated and may be removed.-N <packet limit>β limit the number of packets used for storing captured packets in memory while processing it. If you use it together with the-Coption, both limits apply. Setting this limit will enable the usage of the separate thread per interface. multitasking queen behavior fr fr π§-p,--no-promiscuous-modeβ don't put the interface into promiscuous mode. But real talk: the interface might be in promiscuous mode for some other reason, so-pcannot be used to guarantee that the only traffic captured is traffic sent to or from the machine Dumpcap is running on, broadcast traffic, and multicast traffic to addresses received by that machine. Like, it's not a filter, bestie, don't be fooled. π«Ά
This option can occur multiple times. If you use it before the first occurrence of the -i option, no interface will be put into promiscuous mode. If you use it after an -i option, the interface specified by the last -i option occurring before this option won't be put into promiscuous mode.
-Pβ save files as pcap instead of the default pcapng. In situations that require pcapng, such as capturing from multiple interfaces, this option will be overridden. Also it's deprecated in favor of the-Foption and may be removed. old news, we're moving on π-qβ when capturing packets, don't show the continuous count of packets captured that normally appears when saving a capture to a file; instead, just show a count of packets captured at the end of the capture. On systems that support theSIGINFOsignal β like various BSDs β you can make the current count show up by typing your "status" character (typically Ctrl+T, although on at least some BSDs it might be set to "disabled" by default, so you'd have to explicitly set it to actually use it). iykyk πΈ-Qβ when capturing packets, don't display any of this on the standard error: the initial message saying what interfaces the capture is happening on, the messages saying what file a capture is being written to, the continuous count of packets captured that's normally shown when saving to a file, and the message at the end of the capture with the packet count. This outputs less than the-qoption does β only true errors get shown on the standard error. The quietest of the quiet. π€«
Same deal as -q on systems that support the SIGINFO signal, such as various BSDs: you can make the current count appear by typing your "status" character (typically Ctrl+T, although it might be set to "disabled" by default on at least some BSDs, so you'd have to explicitly set it to use it).
-s <capture snaplen>,--snapshot-length <capture snaplen>β set the default snapshot length to use when capturing live data. No more thansnaplenbytes of each network packet will be read into memory, or saved to disk. A value of0specifies a snapshot length of262144, so that the full packet is captured β and that's the default, bestie. β
This option can occur multiple times. If you use it before the first occurrence of the -i option, it sets the default snapshot length. If you use it after an -i option, it sets the snapshot length for the interface specified by the last -i option occurring before this option. If the snapshot length isn't set specifically, the default snapshot length is used if provided.
-Sβ print statistics for each interface once every second. numbers going brrr π-tβ use a separate thread per interface.--temp-dir <directory>β specifies the directory where temporary files (capture files included) are to be written. Default behavior on UNIX-compatible systems β such as Linux, macOS,*BSD, Solaris, and AIX β is to use the environment variable$TMPDIRif it's set, and the system default, typically/tmp, if it's not. On Windows, the%TEMP%environment variable is used, which typically defaults to%USERPROFILE%\AppData\Local\Temp. π-v,--versionβ print the full version information and exit.-w <outfile>β write raw packet data tooutfile. Use"-"for stdout. π¦-y <capture link type>,--linktype <capture link type>β set the data link type to use while capturing packets. The values reported by-Lare the values you can use here. match made in heaven β¨
This option can occur multiple times. If you use it before the first occurrence of the -i option, it sets the default capture link type. If you use it after an -i option, it sets the capture link type for the interface specified by the last -i option occurring before this option. If the capture link type isn't set specifically, the default capture link type is used if provided.
--application-flavor [wireshark|stratoshark]β set the application flavor. It makes the-Doption output and other behavior suitable for packet capture or for system call and log capture. The default flavor is"wireshark". π¬--capture-comment <comment>β add a capture comment to the output file, if the output file format supports it.
Heads up: this option is only available if we output the captured packets to a single file.
This option may be specified multiple times. Note that Wireshark currently only displays the first comment of a capture file. rude but ok π
--list-time-stamp-typesβ list the time stamp types supported for the interface. If no time stamp type can be set, no time stamp types are listed. empty list is still a list, periodt π--no-optimizeβ do not run the libpcap optimizer when generating code for a capture filter. Super useful if you suspect a bug in the optimizer, or for instructive purposes.
This option can occur multiple times. If you use it before the first occurrence of the -i option, capture filters are not optimized for all interfaces. If you use it after an -i option, the capture filter for the interface specified by the last -i option occurring before this option is not optimized.
--process-info[=basic|full]β record, for each packet, the processes on this host that sent or received it, when the packet belongs to a TCP or UDP socket. The process ID goes in anepb_processid_threadidoption of the packet's block, and a Process Information Block describing the process is written once per output file. Wireshark shows them as theframe.processfields. π₯
With basic, which is the default, a process is described by what identifies it: its ID, name and start time, which is what tools such as netstat show. With full, its executable path, command line, parent process ID and user are recorded as well.
Okay so this part matters, bestie: thosefullfields can be sensitive. A command line can contain a password or a token, and a path can contain the name of a user. They're stored in the capture file as they are, for everybody the file is given to β so usefullonly for files that will be handled accordingly. Withbasicthey are not even read. π
The argument has to be attached with an equals sign, as in --process-info=full. No space, got it?
The processes are found in the operating system's socket tables, so a socket must still exist when its packet is captured β very short-lived sockets can be missed. Which processes can be identified depends on privileges: on Windows, all of them; on Linux, the user's own, or all of them if dumpcap runs as root or has the CAP_SYS_PTRACE capability, which it then keeps, and nothing else, after opening the interfaces; on macOS, the user's own, or all of them if dumpcap runs as root. Not supported on other platforms. Requires the pcapng file format.
--time-stamp-type <type>β change the interface's timestamp method. β°--update-interval <interval>β set the length of time in milliseconds between new packet reports during a capture. It also sets the granularity of file duration conditions. The default value is100ms. π
π DIAGNOSTIC OPTIONS π
okay bestie, these are the log knobs β very βlet me see whatβs happening under the hoodβ energy π
--log-level <level>β sets the active log level. Supported levels, lowest to highest, are"noisy","debug","info","message","warning","critical", and"error". Messages at each level and higher get printed β so"warning"prints"warning","critical", and"error"messages, and"noisy"prints all messages. Levels are case insensitive.--log-fatal <level>β aborts the program if any messages are logged at the specified level or higher. For example,"warning"aborts on any"warning","critical", or"error"messages.--log-fatal-count <count>β the amount of fatal log messages which may pass before the program is aborted.--log-domains <list>β only prints messages for the specified log domains, e.g."GUI,Epan,sshdump". The list of domains must be comma-separated. Can be negated with"!"as the first character (inverts the match).--log-debug <list>β forces the specified domains to log at the"debug"level. List of domains must be comma-separated. Can be negated with"!"as the first character (inverts the match).--log-noisy <list>β forces the specified domains to log at the"noisy"level. List of domains must be comma-separated. Can be negated with"!"as the first character (inverts the match).--log-fatal-domains <list>β aborts the program if any messages are logged for the specified log domains. List of domains must be comma-separated.--log-file <path>β writes log messages and stderr output to the specified file.
π¦ CAPTURE FILTER SYNTAX π¦
For capture filter syntax, go read the manual page of pcap-filter(7) β or, if that doesnβt exist, tcpdump(8) β or, if that doesnβt exist, the wiki at https://gitlab.com/wireshark/wireshark/-/wikis/CaptureFilters.
π SEE ALSO π
Go hang out with wireshark(1), tshark(1), editcap(1), mergecap(1), capinfos(1), pcap(3), and pcap-filter(7) or tcpdump(8).
π NOTES π
Bestie, this is the manual page for Dumpcap 4.7.4. Dumpcap is part of the Wireshark distribution. The latest version of Wireshark can be found at https://www.wireshark.org.
HTML versions of the Wireshark project man pages are available at https://www.wireshark.org/docs/man-pages.
π«Ά AUTHORS π«Ά
Dumpcap is derived from the Wireshark capturing engine code; see the list of authors in the Wireshark man page for a list of authors of that code. periodt π
π thatβs the whole DUMPCAP(1) page, bestie β Dumpcap 4.7.4, dated 2026-10-08. slay π
π¦ where this page comes from
- arch rolling: wireshark-cli 4.7.4-1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms