]> gitweb.fperrin.net Git - iftop.git/blob - iftop.cat
Import de iftop-1.0pre1
[iftop.git] / iftop.cat
1 IFTOP(8)                                                              IFTOP(8)
2
3
4
5 N\bNA\bAM\bME\bE
6        iftop - display bandwidth usage on an interface by host
7
8
9 S\bSY\bYN\bNO\bOP\bPS\bSI\bIS\bS
10        i\bif\bft\bto\bop\bp -\b-h\bh | [-\b-n\bnN\bNp\bpb\bbl\blB\bBP\bP] [-\b-i\bi _\bi_\bn_\bt_\be_\br_\bf_\ba_\bc_\be] [-\b-f\bf _\bf_\bi_\bl_\bt_\be_\br _\bc_\bo_\bd_\be] [-\b-F\bF _\bn_\be_\bt/_\bm_\ba_\bs_\bk] [-\b-G\bG
11        _\bn_\be_\bt_\b6/_\bm_\ba_\bs_\bk_\b6]
12
13 D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
14        i\bif\bft\bto\bop\bp listens to network traffic on a named _\bi_\bn_\bt_\be_\br_\bf_\ba_\bc_\be, or on the  first
15        interface it can find which looks like an external interface if none is
16        specified, and displays a table of current bandwidth usage by pairs  of
17        hosts.   i\bif\bft\bto\bop\bp  must  be run with sufficient permissions to monitor all
18        network traffic on the _\bi_\bn_\bt_\be_\br_\bf_\ba_\bc_\be; see p\bpc\bca\bap\bp(3) for more information, but
19        on most systems this means that it must be run as root.
20
21        By  default, i\bif\bft\bto\bop\bp will look up the hostnames associated with addresses
22        it finds in packets. This can cause substantial traffic of itself,  and
23        may  result in a confusing display. You may wish to suppress display of
24        DNS traffic by using filter code such as n\bno\bot\bt p\bpo\bor\brt\bt d\bdo\bom\bma\bai\bin\bn, or switch  it
25        off  entirely, by using the -\b-n\bn option or by pressing r\br when the program
26        is running.
27
28        By default, i\bif\bft\bto\bop\bp counts all IP packets that pass through  the  filter,
29        and  the  direction of the packet is determined according to the direc-
30        tion the packet is moving across the interface.  Using the -\b-F\bF option it
31        is  possible  to get i\bif\bft\bto\bop\bp to show packets entering and leaving a given
32        network.  For example, i\bif\bft\bto\bop\bp -\b-F\bF 1\b10\b0.\b.0\b0.\b.0\b0.\b.0\b0/\b/2\b25\b55\b5.\b.0\b0.\b.0\b0.\b.0\b0 will analyse packets
33        flowing in and out of the 10.* network.
34
35        Some other filter ideas:
36
37        n\bno\bot\bt e\bet\bth\bhe\ber\br h\bho\bos\bst\bt f\bff\bf:\b:f\bff\bf:\b:f\bff\bf:\b:f\bff\bf:\b:f\bff\bf:\b:f\bff\bf
38               Ignore ethernet broadcast packets.
39
40        p\bpo\bor\brt\bt h\bht\btt\btp\bp a\ban\bnd\bd n\bno\bot\bt h\bho\bos\bst\bt _\bw_\be_\bb_\bc_\ba_\bc_\bh_\be_\b._\be_\bx_\ba_\bm_\bp_\bl_\be_\b._\bc_\bo_\bm
41               Count  web  traffic  only, unless it is being directed through a
42               local web cache.
43
44        i\bic\bcm\bmp\bp   How much bandwidth are users wasting trying to  figure  out  why
45               the network is slow?
46
47
48 O\bOP\bPT\bTI\bIO\bON\bNS\bS
49        -\b-h\bh     Print a summary of usage.
50
51        -\b-n\bn     Don't do hostname lookups.
52
53        -\b-N\bN     Do not resolve port number to service names
54
55        -\b-p\bp     Run  in  promiscuous  mode,  so that traffic which does not pass
56               directly through the specified interface is also counted.
57
58        -\b-P\bP     Turn on port display.
59
60        -\b-l\bl     Display and count datagrams addressed to or from link-local IPv6
61               addresses.  The default is not to display that address category.
62
63        -\b-b\bb     Don't display bar graphs of traffic.
64
65        -\b-B\bB     Display bandwidth rates in bytes/sec rather than bits/sec.
66
67        -\b-i\bi _\bi_\bn_\bt_\be_\br_\bf_\ba_\bc_\be
68               Listen to packets on _\bi_\bn_\bt_\be_\br_\bf_\ba_\bc_\be.
69
70        -\b-f\bf _\bf_\bi_\bl_\bt_\be_\br _\bc_\bo_\bd_\be
71               Use _\bf_\bi_\bl_\bt_\be_\br _\bc_\bo_\bd_\be to select the packets to count. Only IP  packets
72               are  ever counted, so the specified code is evaluated as (\b(_\bf_\bi_\bl_\bt_\be_\br
73               _\bc_\bo_\bd_\be)\b) a\ban\bnd\bd i\bip\bp.
74
75        -\b-F\bF _\bn_\be_\bt/_\bm_\ba_\bs_\bk
76               Specifies an IPv4 network for traffic analysis.   If  specified,
77               iftop  will  only  include  packets  flowing in to or out of the
78               given network, and packet direction is  determined  relative  to
79               the  network  boundary,  rather  than to the interface.  You may
80               specify _\bm_\ba_\bs_\bk as a dotted quad, such as /255.255.255.0, or  as  a
81               single  number specifying the number of bits set in the netmask,
82               such as /24.
83
84        -\b-G\bG _\bn_\be_\bt_\b6/_\bm_\ba_\bs_\bk_\b6
85               Specifies an IPv6 network for traffic  analysis.  The  value  of
86               _\bm_\ba_\bs_\bk_\b6  can be given as a prefix length or as a numerical address
87               string for more compound bitmasking.
88
89        -\b-c\bc _\bc_\bo_\bn_\bf_\bi_\bg _\bf_\bi_\bl_\be
90               Specifies an alternate config file.   If  not  specified,  iftop
91               will  use  ~\b~/\b/.\b.i\bif\bft\bto\bop\bpr\brc\bc if it exists.  See below for a description
92               of config files
93
94
95 D\bDI\bIS\bSP\bPL\bLA\bAY\bY
96        When running, i\bif\bft\bto\bop\bp uses the whole screen to display network usage.  At
97        the  top  of the display is a logarithmic scale for the bar graph which
98        gives a visual indication of traffic.
99
100        The main part of the display lists, for each pair of hosts, the rate at
101        which  data  has been sent and received over the preceding 2, 10 and 40
102        second intervals. The direction of data flow is indicated by arrows, <=
103        and =>. For instance,
104
105        foo.example.com  =>  bar.example.com      1Kb  500b   100b
106                         <=                       2Mb    2Mb    2Mb
107
108        shows,  on  the  first  line, traffic from f\bfo\boo\bo.\b.e\bex\bxa\bam\bmp\bpl\ble\be.\b.c\bco\bom\bm to b\bba\bar\br.\b.e\bex\bxa\bam\bm-\b-
109        p\bpl\ble\be.\b.c\bco\bom\bm; in the preceding 2 seconds, this averaged 1Kbit/s, around half
110        that  amount over the preceding 10s, and a fifth of that over the whole
111        of the last 40s. During each of those intervals, the data sent  in  the
112        other  direction was about 2Mbit/s. On the actual display, part of each
113        line is inverted to give a visual indication  of  the  10s  average  of
114        traffic.  You might expect to see something like this where host f\bfo\boo\bo is
115        making repeated HTTP requests to b\bba\bar\br, which is sending data back  which
116        saturates a 2Mbit/s link.
117
118        By  default,  the  pairs  of hosts responsible for the most traffic (10
119        second average) are displayed at the top of the list.
120
121        At the bottom of the display, various totals are shown, including  peak
122        traffic over the last 40s, total traffic transferred (after filtering),
123        and total transfer rates averaged over 2s, 10s and 40s.
124
125
126 S\bSO\bOU\bUR\bRC\bCE\bE /\b/ D\bDE\bES\bST\bT A\bAG\bGG\bGR\bRE\bEG\bGA\bAT\bTI\bIO\bON\bN
127        By pressing s\bs or d\bd while i\bif\bft\bto\bop\bp is running, all traffic for each  source
128        or  destination  will be aggregated together.  This is most useful when
129        i\bif\bft\bto\bop\bp is run in promiscuous mode, or is run on a gateway machine.
130
131
132 P\bPO\bOR\bRT\bT D\bDI\bIS\bSP\bPL\bLA\bAY\bY
133        S\bS or D\bD toggle the display of source and destination ports respectively.
134        p\bp will toggle port display on/off.
135
136
137 D\bDI\bIS\bSP\bPL\bLA\bAY\bY T\bTY\bYP\bPE\bE
138        t\bt  cycles  through the four line display modes; the default 2-line dis-
139        play, with sent and received traffic on separate lines,  and  3  1-line
140        displays, with sent, received, or total traffic shown.
141
142
143 D\bDI\bIS\bSP\bPL\bLA\bAY\bY O\bOR\bRD\bDE\bER\bR
144        By  default,  the  display is ordered according to the 10s average (2nd
145        column).  By pressing 1\b1, 2\b2 or 3\b3 it is possible to sort by the 1st,  2nd
146        or  3rd  column.    By  pressing  <\b<  or >\b> the display will be sorted by
147        source or destination hostname respectively.
148
149
150 D\bDI\bIS\bSP\bPL\bLA\bAY\bY F\bFI\bIL\bLT\bTE\bER\bRI\bIN\bNG\bG
151        l\bl allows you to enter a POSIX extended regular expression that will  be
152        used  to  filter hostnames shown in the display.  This is a good way to
153        quickly limit what is shown on the display.  Note that this happens  at
154        a  much later stage than filter code, and does not affect what is actu-
155        ally captured.  Display filters DO NOT affect the totals at the  bottom
156        of the screen.
157
158
159 P\bPA\bAU\bUS\bSE\bE D\bDI\bIS\bSP\bPL\bLA\bAY\bY /\b/ F\bFR\bRE\bEE\bEZ\bZE\bE O\bOR\bRD\bDE\bER\bR
160        P\bP will pause the current display.
161
162        o\bo  will freeze the current screen order.  This has the side effect that
163        traffic between hosts not shown on the screen at the time will  not  be
164        shown  at all, although it will be included in the totals at the bottom
165        of the screen.
166
167
168 S\bSC\bCR\bRO\bOL\bLL\bL D\bDI\bIS\bSP\bPL\bLA\bAY\bY
169        j\bj and k\bk will scroll the display of hosts.  This feature is most  useful
170        when the display order is frozen (see above).
171
172
173 F\bFI\bIL\bLT\bTE\bER\bR C\bCO\bOD\bDE\bE
174        f\bf  allows  you  to edit the filter code whilst iftop running.  This can
175        lead to some unexpected behaviour.
176
177
178 C\bCO\bON\bNF\bFI\bIG\bG F\bFI\bIL\bLE\bE
179        iftop can read its configuration from a config file.  If the -\b-c\bc  option
180        is  not  specified,  iftop  will attempt to read its configuration from
181        ~\b~/\b/.\b.i\bif\bft\bto\bop\bpr\brc\bc, if it exists.  Any  command  line  options  specified  will
182        override settings in the config file.
183
184        The config file consists of one configuration directive per line.  Each
185        directive is a name value pair, for example:
186
187        interface: eth0
188
189        sets the network interface.  The following config directives  are  sup-
190        ported:
191
192
193        i\bin\bnt\bte\ber\brf\bfa\bac\bce\be:\b: _\bi_\bf
194               Sets the network interface to _\bi_\bf.
195
196        d\bdn\bns\bs-\b-r\bre\bes\bso\bol\blu\but\bti\bio\bon\bn:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
197               Controls reverse lookup of IP addresses.
198
199        p\bpo\bor\brt\bt-\b-r\bre\bes\bso\bol\blu\but\bti\bio\bon\bn:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
200               Controls conversion of port numbers to service names.
201
202        f\bfi\bil\blt\bte\ber\br-\b-c\bco\bod\bde\be:\b: _\bb_\bp_\bf
203               Sets the filter code to _\bb_\bp_\bf.
204
205        s\bsh\bho\bow\bw-\b-b\bba\bar\brs\bs:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
206               Controls display of bar graphs.
207
208        p\bpr\bro\bom\bmi\bis\bsc\bcu\buo\bou\bus\bs:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
209               Puts the interface into promiscuous mode.
210
211        p\bpo\bor\brt\bt-\b-d\bdi\bis\bsp\bpl\bla\bay\by:\b: _\b(_\bo_\bf_\bf_\b|_\bs_\bo_\bu_\br_\bc_\be_\b-_\bo_\bn_\bl_\by_\b|_\bd_\be_\bs_\bt_\bi_\bn_\ba_\bt_\bi_\bo_\bn_\b-_\bo_\bn_\bl_\by_\b|_\bo_\bn_\b)
212               Controls display of port numbers.
213
214        l\bli\bin\bnk\bk-\b-l\blo\boc\bca\bal\bl:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
215               Determines displaying of link-local IPv6 addresses.
216
217        h\bhi\bid\bde\be-\b-s\bso\bou\bur\brc\bce\be:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
218               Hides source host names.
219
220        h\bhi\bid\bde\be-\b-d\bde\bes\bst\bti\bin\bna\bat\bti\bio\bon\bn:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
221               Hides destination host names.
222
223        u\bus\bse\be-\b-b\bby\byt\bte\bes\bs:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
224               Use bytes for bandwidth display, rather than bits.
225
226        s\bso\bor\brt\bt:\b: _\b(_\b2_\bs_\b|_\b1_\b0_\bs_\b|_\b4_\b0_\bs_\b|_\bs_\bo_\bu_\br_\bc_\be_\b|_\bd_\be_\bs_\bt_\bi_\bn_\ba_\bt_\bi_\bo_\bn_\b)
227               Sets which column is used to sort the display.
228
229        l\bli\bin\bne\be-\b-d\bdi\bis\bsp\bpl\bla\bay\by:\b: _\b(_\bt_\bw_\bo_\b-_\bl_\bi_\bn_\be_\b|_\bo_\bn_\be_\b-_\bl_\bi_\bn_\be_\b-_\bb_\bo_\bt_\bh_\b|_\bo_\bn_\be_\b-_\bl_\bi_\bn_\be_\b-_\bs_\be_\bn_\bt_\b|_\bo_\bn_\be_\b-_\bl_\bi_\bn_\be_\b-_\br_\be_\bc_\be_\bi_\bv_\be_\bd_\b)
230               Controls the appearance of each item in the display.
231
232        s\bsh\bho\bow\bw-\b-t\bto\bot\bta\bal\bls\bs:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
233               Shows cumulative total for each item.
234
235        l\blo\bog\bg-\b-s\bsc\bca\bal\ble\be:\b: _\b(_\by_\be_\bs_\b|_\bn_\bo_\b)
236               Use a logarithmic scale for bar graphs.
237
238        m\bma\bax\bx-\b-b\bba\ban\bnd\bdw\bwi\bid\bdt\bth\bh:\b: _\bb_\bw
239               Fixes  the  maximum  for  the bar graph scale to _\bb_\bw, e.g. "10M".
240               Note that the value has to always be in bits, regardless if  the
241               option to display in bytes has been chosen.
242
243        n\bne\bet\bt-\b-f\bfi\bil\blt\bte\ber\br:\b: _\bn_\be_\bt_\b/_\bm_\ba_\bs_\bk
244               Defines an IP network boundary for determining packet direction.
245
246        n\bne\bet\bt-\b-f\bfi\bil\blt\bte\ber\br6\b6:\b: _\bn_\be_\bt_\b6_\b/_\bm_\ba_\bs_\bk_\b6
247               Defines an IPv6 network boundary for determining  packet  direc-
248               tion.
249
250        s\bsc\bcr\bre\bee\ben\bn-\b-f\bfi\bil\blt\bte\ber\br:\b: _\br_\be_\bg_\be_\bx_\bp
251               Sets a regular expression to filter screen output.
252
253
254 Q\bQU\bUI\bIR\bRK\bKS\bS (\b(a\bak\bka\ba t\bth\bhe\bey\by'\b'r\bre\be f\bfe\bea\bat\btu\bur\bre\bes\bs,\b, n\bno\bot\bt b\bbu\bug\bgs\bs)\b)
255        There are some circumstances in which iftop may not do what you expect.
256        In most cases what it is doing is logical, and we believe it is correct
257        behaviour,  although  I'm happy to hear reasoned arguments for alterna-
258        tive behaviour.
259
260        T\bTo\bot\bta\bal\bls\bs d\bdo\bon\bn'\b't\bt a\bad\bdd\bd u\bup\bp
261
262        There are several reasons why the totals may not appear to add up.  The
263        most  obvious  is  having a screen filter in effect, or screen ordering
264        frozen.  In this case some captured information is not being  shown  to
265        you, but is included in the totals.
266
267        A  more subtle explanation comes about when running in promiscuous mode
268        without specifying a -\b-F\bF option.  In this case there is no easy  way  to
269        assign  the  direction  of  traffic between two third parties.  For the
270        purposes of the main display this is done in an arbitrary  fashion  (by
271        ordering  of  IP  addresses),  but  for  the sake of totals all traffic
272        between other hosts is accounted as incoming, because that's what it is
273        from  the point of view of your interface.  The -\b-F\bF option allows you to
274        specify an arbitrary network boundary,  and  to  show  traffic  flowing
275        across it.
276
277        P\bPe\bea\bak\bk t\bto\bot\bta\bal\bls\bs d\bdo\bon\bn'\b't\bt a\bad\bdd\bd u\bup\bp
278
279        Again,  this is a feature.  The peak sent and peak received didn't nec-
280        essarily happen at the same time.  The peak total  is  the  maximum  of
281        sent plus received in each captured time division.
282
283        C\bCh\bha\ban\bng\bgi\bin\bng\bg t\bth\bhe\be f\bfi\bil\blt\bte\ber\br c\bco\bod\bde\be d\bdo\boe\bes\bsn\bn'\b't\bt s\bse\bee\bem\bm t\bto\bo w\bwo\bor\brk\bk
284
285        Give  it  time.  Changing the filter code affects what is captured from
286        the time that you entered it, but most of what is  on  the  display  is
287        based  on  some  fraction  of  the last 40s window of capturing.  After
288        changing the filter there may be entries on the display that are disal-
289        lowed by the current filter for up to 40s.  DISPLAY FILTERING has imme-
290        diate effect and does not affect what is captured.
291
292
293 F\bFI\bIL\bLE\bES\bS
294        ~\b~/\b/.\b.i\bif\bft\bto\bop\bpr\brc\bc
295               Configuration file for iftop.
296
297
298 S\bSE\bEE\bE A\bAL\bLS\bSO\bO
299        t\btc\bcp\bpd\bdu\bum\bmp\bp(8), p\bpc\bca\bap\bp(3), d\bdr\bri\bif\bft\btn\bne\bet\bt(1).
300
301
302 A\bAU\bUT\bTH\bHO\bOR\bR
303        Paul Warren <pdw@ex-parrot.com>
304
305
306 V\bVE\bER\bRS\bSI\bIO\bON\bN
307        $Id: iftop.8,v 1.27 2010/11/27 11:06:12 pdw Exp $
308
309
310 C\bCO\bOP\bPY\bYI\bIN\bNG\bG
311        This program is free software; you can redistribute it and/or modify it
312        under  the  terms of the GNU General Public License as published by the
313        Free Software Foundation; either version 2 of the License, or (at  your
314        option) any later version.
315
316        This  program  is  distributed  in the hope that it will be useful, but
317        WITHOUT ANY  WARRANTY;  without  even  the  implied  warranty  of  MER-
318        CHANTABILITY  or  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
319        Public License for more details.
320
321        You should have received a copy of the GNU General Public License along
322        with this program; if not, write to the Free Software Foundation, Inc.,
323        675 Mass Ave, Cambridge, MA 02139, USA.
324
325
326
327
328                                                                       IFTOP(8)