File: capstats.8

package info (click to toggle)
capstats 0.22-2
  • links: PTS, VCS
  • area: main
  • in suites: buster, sid
  • size: 416 kB
  • sloc: cpp: 498; sh: 163; makefile: 36
file content (111 lines) | stat: -rw-r--r-- 3,103 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
.\"                                      Hey, EMACS: -*- nroff -*-
.\" First parameter, NAME, should be all caps
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
.\" other parameters are allowed: see man(7), man(1)
.TH CAPSTATS 8 "January 15, 2010"
.\" Please adjust this date whenever revising the manpage.
.\"
.\" Some roff macros, for reference:
.\" .nh        disable hyphenation
.\" .hy        enable hyphenation
.\" .ad l      left justify
.\" .ad b      justify to both left and right margins
.\" .nf        disable filling
.\" .fi        enable filling
.\" .br        insert line break
.\" .sp <n>    insert n+1 empty lines
.\" for manpage-specific macros, see man(7)
.SH NAME
capstats \- print statistics about the current load on a network interface
.SH SYNOPSIS
.B capstats
.RI "[ options ] -i " "interface"
.br
.SH DESCRIPTION
This manual page documents briefly the
.B capstats
command.
.PP
.B capstats
is a program that prints statistics about the current load on a
network interface using libpcap.  It reports statistics per time interval
and/or for the tool's total run-time.

Here's an example output with output in one-second intervals until CTRL-C is hit:

.ad l
>capstats -i eth0 -I 1
.br
1186620936.890567 pkts=12747 kpps=12.6 kbytes=10807 mbps=87.5 nic_pkts=12822 nic_drops=0 u=960 t=11705 i=58 o=24 nonip=0
.br
1186620937.901490 pkts=13558 kpps=13.4 kbytes=11329 mbps=91.8 nic_pkts=13613 nic_drops=0 u=1795 t=24339 i=119 o=52 nonip=0
.br
1186620938.912399 pkts=14771 kpps=14.6 kbytes=13659 mbps=110.7 nic_pkts=14781 nic_drops=0 u=2626 t=38154 i=185 o=111 nonip=0
.br
1186620939.012446 pkts=1332 kpps=13.3 kbytes=1129 mbps=92.6 nic_pkts=1367 nic_drops=0 u=2715 t=39387 i=194 o=112 nonip=0
.br
=== Total
.br
1186620939.012483 pkts=42408 kpps=13.5 kbytes=36925 mbps=96.5 nic_pkts=1 nic_drops=0 u=2715 t=39387 i=194 o=112 nonip=0
.ad b

.SH OPTIONS
These programs follow the usual GNU command line syntax, with long
options starting with two dashes (`-').
A summary of options is included below.

.TP
.BI "\-i, \-\-interface " interface
.RI "Listen on " interface

.TP
.B \-d, \-\-dag
Use native DAG API if capstats was built with DAG support.

.TP
.BI "\-f, \-\-filter " filter
BPF filter

.TP
.BI "\-I, \-\-interval " secs
Stats logging interval

.TP
.B \-l, \-\-syslog
Use syslog rather than print to stderr
.TP
.BI "\-n, \-\-number " count
.RI "Stop after outputting " count " intervals"

.TP
.B "\-p, \-\-payload" n
Verifies that packets' payloads consist entirely of bytes of the given value.

.TP
.B "\-q, \-\-quiet" count
Suppress output, exit code indicates >= count packets received.

.TP
.BI "\-S, \-\-size " size
Verify packets to have given size

.TP
.BI "\-s, \-\-snaplen " size
.RI "Use pcap snaplen " size

.TP
.B \-v, \-\-version
Print version and exit

.TP
.BI "\-w, \-\-write " filename
.RI "Write packets to " filename

.SH SEE ALSO
.BR tcpdump (8),
.br
.SH AUTHOR
capstats was written by Robin Sommer <robin@icir.org>
.PP
This manual page was written by Justin Azoff <JAzoff@uamail.albany.edu>,
for the Debian project (but may be used by others).